Skip to content

Commit

Permalink
chg: [API] Updated contrib/update.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
cedricbonhomme committed Nov 23, 2023
1 parent d622d53 commit 9c79d99
Showing 1 changed file with 24 additions and 3 deletions.
27 changes: 24 additions & 3 deletions contrib/update.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,32 @@ NC='\033[0m' # No Color
set -e
#set -x

# Retrieve the update from the repository
git pull origin main --tags
npm ci
. env/bin/activate
# pip install -e .
pip install


# Search for a virtual environment folder in the project root
VENV_NAME="venv"
PROJECT_ROOT=$(pwd)

# Find the virtual environment folder
VENV_PATH=$(find "$PROJECT_ROOT" -type d -name "$VENV_NAME" 2>/dev/null | head -n 1)

if [ -z "$VENV_PATH" ]; then
echo "Virtual environment not found in the project root."
exit 1
fi

# Activate the virtual environment
source "$VENV_PATH/bin/activate"

# source env/bin/activate



pip install -e .
# pip install
python manage.py collectstatic --no-input
python manage.py migrate
# python manage.py compilemessages
Expand Down

0 comments on commit 9c79d99

Please sign in to comment.