mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-22 15:03:28 +00:00
19 lines
478 B
Bash
19 lines
478 B
Bash
# Clean up top-level tests directory in site-package installation.
|
|
# shellcheck shell=bash
|
|
|
|
echo "Sourcing python-remove-tests-dir-hook"
|
|
|
|
pythonRemoveTestsDir() {
|
|
echo "Executing pythonRemoveTestsDir"
|
|
|
|
# shellcheck disable=SC2154
|
|
rm -rf "$out/@pythonSitePackages@/tests"
|
|
rm -rf "$out/@pythonSitePackages@/test"
|
|
|
|
echo "Finished executing pythonRemoveTestsDir"
|
|
}
|
|
|
|
if [ -z "${dontUsePythonRemoveTestsDir-}" ]; then
|
|
postFixupHooks+=(pythonRemoveTestsDir)
|
|
fi
|