- Remove executable permissions from configuration files (.editorconfig, .env.example, .gitignore) - Remove executable permissions from documentation files (README.md, LICENSE, SECURITY.md) - Remove executable permissions from web assets (HTML, CSS, JS files) - Remove executable permissions from data files (JSON, SQL, YAML, requirements.txt) - Remove executable permissions from source code files across all apps - Add executable permissions to Python
27 lines
543 B
Bash
27 lines
543 B
Bash
#!/bin/bash
|
|
set -e
|
|
|
|
# Pre-removal script for aitbc-cli
|
|
|
|
case "$1" in
|
|
remove|upgrade|failed-upgrade)
|
|
# Remove symlink
|
|
if [ -L "/usr/local/bin/aitbc" ]; then
|
|
rm -f /usr/local/bin/aitbc
|
|
fi
|
|
|
|
# Remove virtual environment (optional, keep data)
|
|
# VENV_PATH="/opt/aitbc/venv"
|
|
# if [ -d "$VENV_PATH" ]; then
|
|
# rm -rf "$VENV_PATH"
|
|
# fi
|
|
;;
|
|
|
|
disappear)
|
|
# Package is being removed
|
|
rm -f /usr/local/bin/aitbc
|
|
;;
|
|
esac
|
|
|
|
exit 0
|