pkgs.writePython*: normalize arguments
This commit is contained in:
@@ -284,7 +284,7 @@ pkgs: oldpkgs: {
|
|||||||
${pkgs.cabal2nix}/bin/cabal2nix ${path} > $out
|
${pkgs.cabal2nix}/bin/cabal2nix ${path} > $out
|
||||||
'');
|
'');
|
||||||
|
|
||||||
writePython2 = deps:
|
writePython2 = name: deps:
|
||||||
let
|
let
|
||||||
py = pkgs.python2.withPackages(ps: attrVals deps ps);
|
py = pkgs.python2.withPackages(ps: attrVals deps ps);
|
||||||
in
|
in
|
||||||
@@ -293,12 +293,12 @@ pkgs: oldpkgs: {
|
|||||||
check = pkgs.writeDash "python2check.sh" ''
|
check = pkgs.writeDash "python2check.sh" ''
|
||||||
exec ${pkgs.python2Packages.flake8}/bin/flake8 --show-source "$1"
|
exec ${pkgs.python2Packages.flake8}/bin/flake8 --show-source "$1"
|
||||||
'';
|
'';
|
||||||
};
|
} name;
|
||||||
|
|
||||||
writePython2Bin = d: name:
|
writePython2Bin = name:
|
||||||
pkgs.writePython2 d "/bin/${name}";
|
pkgs.writePython2 "/bin/${name}";
|
||||||
|
|
||||||
writePython3 = deps:
|
writePython3 = name: deps:
|
||||||
let
|
let
|
||||||
py = pkgs.python3.withPackages(ps: attrVals deps ps);
|
py = pkgs.python3.withPackages(ps: attrVals deps ps);
|
||||||
in
|
in
|
||||||
@@ -307,10 +307,10 @@ pkgs: oldpkgs: {
|
|||||||
check = pkgs.writeDash "python3check.sh" ''
|
check = pkgs.writeDash "python3check.sh" ''
|
||||||
exec ${pkgs.python3Packages.flake8}/bin/flake8 --show-source "$1"
|
exec ${pkgs.python3Packages.flake8}/bin/flake8 --show-source "$1"
|
||||||
'';
|
'';
|
||||||
};
|
} name;
|
||||||
|
|
||||||
writePython3Bin = d: name:
|
writePython3Bin = name:
|
||||||
pkgs.writePython3 d "/bin/${name}";
|
pkgs.writePython3 "/bin/${name}";
|
||||||
|
|
||||||
writeSed = pkgs.makeScriptWriter {
|
writeSed = pkgs.makeScriptWriter {
|
||||||
interpreter = "${pkgs.gnused}/bin/sed -f";
|
interpreter = "${pkgs.gnused}/bin/sed -f";
|
||||||
|
|||||||
Reference in New Issue
Block a user