Update PR

This commit is contained in:
Jaby
2025-01-08 22:13:27 +01:00
committed by Jaby
parent 4bbde2ae95
commit 1a165e59f1
3 changed files with 14 additions and 9 deletions

View File

@@ -2,12 +2,16 @@
podman build -t jaby_engine .
if [[ -z "${JABY_ENGINE_PATH}" ]]; then
echo "Setting JABY_ENGINE_PATH to parent folder"
echo "Setting JABY_ENGINE_PATH to parent folder"
SCRIPT_DIR="$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" &> /dev/null && pwd)"
JABY_ENGINE_PATH="$(dirname "$SCRIPT_DIR")"
cat << End >> ~/.profile
export JABY_ENGINE_PATH="$JABY_ENGINE_PATH"
End
source ~/.profile
SCRIPT_DIR="$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" &> /dev/null && pwd)"
export JABY_ENGINE_PATH="$(dirname "$SCRIPT_DIR")"
if cat /etc/passwd | grep $USER | grep bash > /dev/null; then
# Bash found
echo "export JABY_ENGINE_PATH="$JABY_ENGINE_PATH"" >> ~/.bashrc
else
# No bash found
echo "Please add export JABY_ENGINE_PATH="$JABY_ENGINE_PATH" to your shell profile"
fi
fi