oppiliappan / statix

lints and suggestions for the nix programming language
https://git.peppe.rs/languages/statix/about
MIT License
552 stars 21 forks source link

Add a check for `lib` being the first in the pattern #49

Open viraptor opened 2 years ago

viraptor commented 2 years ago

This is a nixpkgs policy.

Not adding a replacement suggestion at this point, because it seems very tricky to preserve the formatting and potential comments when reordering.

ilkecan commented 1 year ago

I think this should be disabled by default if merged. nixpkgs is a single repository but there are countless other repositories that have Nix code inside them.

There could be a nixpkgs specific flag like --nixpkgs to enable lints such as this.