Logo

dev-resources.site

for different kinds of informations.

TIL - ๐Ÿงน unimport linter formatter

Published at
12/13/2020
Categories
python
linting
formatting
Author
yakky
Categories
3 categories in total
python
open
linting
open
formatting
open
Author
5 person written this
yakky
open
TIL - ๐Ÿงน unimport linter formatter

Thanks to this Jeff Triplets tweet I discovered unimport, which is an interesting tool to detect unused imports (like flake8 would do) and to remove them from the code.

And the cherry on top it's that it can scan the requirements file and detect unused dependencies (which is probably even more important).

Historically this has not been a problem for me (or Nephila team), as flake8 is already well ingrained in our workflow, so we are used to handle code cleanup before committing.

But as I sometimes inherit a large codebase with messy code, and it's awesome how much you can achieve with the right tools.

Currently isort + black + pyupgrade already do a really good job, but adding unimport to the equation is ๐Ÿ’ฅ: a much nicer codebase with zero effort

I will surely give it a more in depth test, and I might add to my linting reference toolbox.

Shootout to Hakan ร‡elik for this package, and its awesome documentation.

linting Article's
30 articles in total
Favicon
How to Configure VSCode for Auto Formatting and Linting in Python
Favicon
Level Up Your OpenAPI Specs using Linting
Favicon
Most elemental code formatting for Typescript/Javascript: .editorconfig vs prettier
Favicon
standardrb, but more
Favicon
Introducing Japr - The Project Linter
Favicon
Level Up Your TypeScript Projects: Discover the Power of ESLint and Prettier
Favicon
Interview with Greg Molnar - Rails developer and penetration tester
Favicon
Setting WordPress Coding Standards per project using Composer
Favicon
Linting Proto Files With Buf
Favicon
ESLint: The Hows, Whys, and Who Behind It
Favicon
Puppet-lint: Soft dependency conflicts after updating
Favicon
Eslint rule to restrict imports
Favicon
Laravel Tooling: 4 tools for static analysis
Favicon
Terraform: Variable validation with samples
Favicon
An Incremental Approach to Linting to Your Projects
Favicon
Add EsLint to existing Angular Project and Configure WebStorm
Favicon
Quick ESLint guide + VsCode ESLint on save
Favicon
Chickity-check yo self before you wreck yo self!
Favicon
How to configure Eslint in Gatsby projects
Favicon
Automatically sorting your Tailwind CSS class names
Favicon
Setting up ESLint + Prettier
Favicon
Incrementally adding Stylelint rules with Betterer
Favicon
Conventional Git Commit Messages and Linting
Favicon
ยฟQuรฉ es Linting y ESLint?
Favicon
My 2020 Python linting setup: How I Learned to Stop Worrying and Love the automated code formatting
Favicon
ESLint not working in VSCode? Help build a troubleshooting checklist!
Favicon
SERIES: React Native (Step by Step) - Working with Typescript and Linting
Favicon
Adding Markdown Linting to my Blogโ€™s Build Process with GitHub Actions and markdownlint
Favicon
TIL - ๐Ÿงน unimport linter formatter
Favicon
Adding New Lint Rules Without the Fuss

Featured ones: