FIx a bug in update procedure and general code maintenance (#3974)

This commit is contained in:
Slaviša Arežina 2025-04-22 11:51:50 +02:00 committed by GitHub
parent 3297df1d50
commit 0373324653
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 43 additions and 44 deletions

View File

@ -35,10 +35,9 @@ function update_script() {
msg_info "Updating $APP to v${RELEASE}"
temp_file=$(mktemp)
cd $temp_file
curl -fsSL "https://github.com/wger-project/wger/archive/refs/tags/$RELEASE.tar.gz" -o "$temp_file"
tar xzf $temp_file
cp -rf wger-$RELEASE/* /home/wger/src
tar xzf "$temp_file"
cp -rf wger-"$RELEASE"/* /home/wger/src
cd /home/wger/src
python3 manage.py migrate &>/dev/null
yarn install &>/dev/null
@ -52,7 +51,7 @@ curl -fsSL "https://github.com/wger-project/wger/archive/refs/tags/$RELEASE.tar.
msg_ok "Started $APP"
msg_info "Cleaning Up"
rm -rf $temp_file
rm -rf "$temp_file"
msg_ok "Cleanup Completed"
msg_ok "Update Successful"