# Tool for cleaning up imports?

**URL:** https://discourse.julialang.org/t/tool-for-cleaning-up-imports/132482
**Category:** General Usage
**Created:** [September 18, 2025, 9:15am UTC](https://discourse.julialang.org/t/tool-for-cleaning-up-imports/132482 "2025-09-18T09:15:35Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![jw3126](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jw3126/32/3086_2.png) [@jw3126](https://discourse.julialang.org/u/jw3126)
#### Post date: [September 18, 2025, 9:15am UTC](https://discourse.julialang.org/t/tool-for-cleaning-up-imports/132482/1 "2025-09-18T09:15:35Z")

</div>

Is there a tool for cleaning up import statements? When a package grows, I often end up with a long and messy list of imports that usually contains many duplicate imports.  
Instead, I would like to have each import once and sorted alphabetically.  
Is there a tool that can do this for me? In the codebase I have in mind, there are many somewhat tricky corner cases. For instance submodules, multi-line imports, import statements in string literals etc.

---

<div class="post-metadata">

### Author: ![gdalle](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gdalle/32/27854_2.png) [@gdalle](https://discourse.julialang.org/u/gdalle)
#### Post date: [September 18, 2025, 12:35pm UTC](https://discourse.julialang.org/t/tool-for-cleaning-up-imports/132482/2 "2025-09-18T12:35:44Z")

</div>

Not quite what you are asking for but ExplicitImports.jl is closely related
