Synthetica9 / nix-linter

Linter for the Nix expression language
BSD 3-Clause "New" or "Revised" License
158 stars 16 forks source link

Consider inline switches to activate/deactivate checks for expressions #49

Open NobbZ opened 3 years ago

NobbZ commented 3 years ago

Flakes require that their overlays arguments are named final and prev, despite if they are used or not.

Having them named differently (even _, _final or _prev) makes nix flake check fail.

Even though I already filed NixOS/nix#4416, I think the following proposal could help mitigate the flake issue as well as #41:

Give control over checks to comments in source code. Similar to python linters allow for magic comments, or how elixirs credo does as well and probably a lot of other linters do.

Synthetica9 commented 3 years ago

Would be nice, but this currently doesn't parse comments so I don't see a way to do this.