1
1
mirror of https://github.com/divnix/digga.git synced 2024-11-23 20:22:04 +03:00

replace nixfmt with nixpkgs-fmt

nixpkgs-fmt looks like it is going to be the standard formatter for
nixpkgs, so we should follow suite.
This commit is contained in:
Timothy DeHerrera 2020-07-30 22:05:36 -06:00
parent 3501100952
commit 9ba71d5b62
No known key found for this signature in database
GPG Key ID: 8985725DB5B0C122
4 changed files with 5 additions and 5 deletions

View File

@ -6,11 +6,11 @@ the `template` branch to provide a host of useful NixOS configurations available
"out of the box". If you wish to contribute such an expression please follow
these guidelines:
* format your code with [`nixfmt`][nixfmt]
* format your code with [`nixpkgs-fmt`][nixpkgs-fmt]
* The commit message follows the same semantics as [nixpkgs][nixpkgs].
* You can use a `#` symbol to specify ambiguities. For example,
`develop#zsh: <rest of commit message>` would tell me that your updating the
`zsh` subprofile living under the `develop` profile.
[nixfmt]: https://github.com/serokell/nixfmt
[nixpkgs-fmt]: https://github.com/nix-community/nixpkgs-fmt
[nixpkgs]: https://github.com/NixOS/nixpkgs

View File

@ -6,7 +6,7 @@
kak-lsp
kakoune-config
kakoune-unwrapped
nixfmt
nixpkgs-fmt
python3Packages.python-language-server
rustup
nix-linter

View File

@ -4,7 +4,7 @@ hook -group lint global WinSetOption filetype=nix %{
set buffer lintcmd '/etc/xdg/kak/autoload/lint/nix.sh $1'
lint-enable
set buffer formatcmd "nixfmt"
set buffer formatcmd "nixpkgs-fmt"
hook buffer BufWritePre .* %{
format
lint

View File

@ -1,6 +1,6 @@
#!/usr/bin/env zsh
nix-linter $1 2>&1 | < /dev/stdin > /tmp/lint.out
nix-linter -W all $1 2>&1 | < /dev/stdin > /tmp/lint.out
if head -1 /tmp/lint.out | grep Failure &> /dev/null; then
sed -n 2p /tmp/lint.out | tr '\n' ' '
printf "error: "