templates/python: add command check
to run all checks
This commit is contained in:
parent
f7388021ae
commit
908a79be0e
@ -15,6 +15,9 @@
|
|||||||
ps.pip
|
ps.pip
|
||||||
]
|
]
|
||||||
);
|
);
|
||||||
|
checkScript = pkgs.writeScriptBin "check" ''
|
||||||
|
nix build -f . tests.check -L "$@"
|
||||||
|
'';
|
||||||
devShell = pkgs.mkShell {
|
devShell = pkgs.mkShell {
|
||||||
packages = [
|
packages = [
|
||||||
pkgs.ruff
|
pkgs.ruff
|
||||||
@ -37,7 +40,7 @@
|
|||||||
--editable $repo_root && \
|
--editable $repo_root && \
|
||||||
cp -a pyproject.toml $tmp_path/pyproject.toml
|
cp -a pyproject.toml $tmp_path/pyproject.toml
|
||||||
fi
|
fi
|
||||||
export PATH="$tmp_path/bin:$PATH"
|
export PATH="$tmp_path/bin:${checkScript}/bin:$PATH"
|
||||||
export PYTHONPATH="$repo_root:$tmp_path/${pythonWithDeps.sitePackages}"
|
export PYTHONPATH="$repo_root:$tmp_path/${pythonWithDeps.sitePackages}"
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user