treefmt: fix eval warnings

This commit is contained in:
Jörg Thalheim 2023-08-06 18:49:32 +02:00 committed by mergify[bot]
parent a749e7c748
commit 68c4ce65a0

View file

@ -5,7 +5,7 @@
programs.prettier.enable = true; programs.prettier.enable = true;
programs.prettier.package = pkgs.writeShellScriptBin "prettier" '' programs.prettier.package = pkgs.writeShellScriptBin "prettier" ''
export NODE_PATH=${pkgs.nodePackages.prettier-plugin-toml}/lib/node_modules export NODE_PATH=${pkgs.nodePackages.prettier-plugin-toml}/lib/node_modules
exec ${lib.getExe pkgs.nodePackages.prettier} "$@" exec ${pkgs.nodePackages.prettier}/bin/prettier "$@"
''; '';
programs.clang-format.enable = true; programs.clang-format.enable = true;
@ -16,13 +16,13 @@
options = [ options = [
"-eucx" "-eucx"
'' ''
${pkgs.lib.getExe pkgs.deadnix} --edit "$@" ${pkgs.deadnix}/bin/deadnix --edit "$@"
for i in "$@"; do for i in "$@"; do
${pkgs.lib.getExe pkgs.statix} fix "$i" ${pkgs.statix}/bin/statix fix "$i"
done done
${pkgs.lib.getExe pkgs.nixpkgs-fmt} "$@" ${pkgs.nixpkgs-fmt}/bin/nixpkgs-fmt "$@"
'' ''
"--" "--"
]; ];
@ -39,8 +39,8 @@
options = [ options = [
"-eucx" "-eucx"
'' ''
${pkgs.lib.getExe pkgs.python3.pkgs.black} "$@" ${pkgs.python3.pkgs.black}/bin/black "$@"
${pkgs.lib.getExe pkgs.ruff} --fix "$@" ${pkgs.ruff}/bin/ruff --fix "$@"
'' ''
"--" # this argument is ignored by bash "--" # this argument is ignored by bash
]; ];