Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nixpkgs-fmt as nix-indent-function #88

Open
alexarice opened this issue Aug 30, 2019 · 2 comments
Open

nixpkgs-fmt as nix-indent-function #88

alexarice opened this issue Aug 30, 2019 · 2 comments

Comments

@alexarice
Copy link

Are there any plans to make an indent function based on nixpkgs-fmt or at least one that agrees with nixpkgs-fmt?

@johnae
Copy link

johnae commented Feb 12, 2020

You can easily just do what I do:

(customize-set-variable 'nix-nixfmt-bin "nixpkgs-fmt")

@tadfisher
Copy link

AFAICT, the only indentation-related change needed is to align expressions with in. I did this by adding the following to nix-mode-hook:

(smie-config-local '((0 :after "in" nil)))

Do we want to standardize on the nixpkgs-fmt style and use this as the default in nix-smie-rules? It would be a quick PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants