buildPython hooks: format with shfmt

This commit is contained in:
Yueh-Shun Li
2024-09-10 23:15:40 +08:00
parent 7ba9e4244b
commit 57c2e5683d
14 changed files with 52 additions and 53 deletions
@@ -5,10 +5,10 @@ echo "Sourcing python-remove-bin-bytecode-hook.sh"
# It may happen there are executables with a .py extension for which
# bytecode is generated. This hook removes that bytecode.
pythonRemoveBinBytecodePhase () {
pythonRemoveBinBytecodePhase() {
if [ -d "$out/bin" ]; then
rm -rf "$out/bin/__pycache__" # Python 3
find "$out/bin" -type f -name "*.pyc" -delete # Python 2
rm -rf "$out/bin/__pycache__" # Python 3
find "$out/bin" -type f -name "*.pyc" -delete # Python 2
fi
}