-
Notifications
You must be signed in to change notification settings - Fork 49
Description
Is your feature request related to a problem? Please describe.
Treefmt is a great tool, but it doesn't take away the burdon of sourcing the used commands.
However, in UX categories, that would be in the ballpark of 50% of additional value (see Devenv, Fleek, Bob, etc).
treefmt-nix doesn't cut the deal, because it requires mental overhead, is not dead simple and interferes with my nix-lib project intent which is not commonly about boilerplate tooling or potentially not a nix project at all.
Describe the solution you'd like
- Setup and maintenance of CI should be as simple as:
- name: Install nix
uses: nixbuild/nix-quick-install-action@v22
- name: Check formatting
run: nix run nixpkgs#treefmt -- . --fail-on-change --no-cache(non-pinning related issues with the tooling formatting are a rare "black-swan" in the horizons of this lifecycle, so we accept them in turn for the 50% additional UX)
- Set up and usage of
treefmtshould be as easy as:
- add
treefmt.toml - run
treefmt- for Nix users
which nix, this means feature-flagged (onwhich nix) profit - for no-nix users, this means no deterioration of their current expectations and a pretext to
sh <(curl -L https://nixos.org/nix/install), which might be a faster resolution of their problem at hand than any alternative course of action.
- for Nix users
Describe alternatives you've considered
treefmt-nix, manual management. It doesn't cut the deal, because it doesn't keep out of my way.
Additional context
I want to do a PR / contribution. Would it be accepted?
nix-community/nix-index-database#44
In Github Actions a hypothetical and arbitrarily pinned nix/nixpkgs could speed up time-to-first-feedback some bits on style checks as it would already have nixpkgs downloaded` and - alas - eval cached.
Potentially, this implementation could attempt to fetch static builds where available to improve the situation further.