Skip to content

Commit

Permalink
Fix addon update recognition
Browse files Browse the repository at this point in the history
  • Loading branch information
Jean28518 committed Apr 18, 2024
1 parent 6cd77f2 commit 89548ca
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/lac/unix/unix_scripts/maintenance/update_everything.sh
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,13 @@ fi
# Update all addons which are located in /usr/share/linux-arbeitsplatz/unix/unix_scripts/addons
for ADDON in /usr/share/linux-arbeitsplatz/unix/unix_scripts/addons/*; do
if [ -d "$ADDON" ]; then
# Get folder name from path
# Get folder name from path.
ADDON_NAME=$(basename $ADDON)
if [ "$(eval "echo \$${ADDON_NAME}_AUTOMATIC_UPDATES")" == "True" ]; then
# Capitalize the addon name and replace "-" with "_" (because of the variable names in unix.conf)
ADDON_VAR_NAME=$(echo $ADDON_NAME | sed -e 's/\(.*\)/\U\1/' -e 's/-/_/g')
if [ "$(eval "echo \$${ADDON_VAR_NAME}_AUTOMATIC_UPDATES")" == "True" ]; then
echo "Starting update of $ADDON_NAME at $DATE" >> ../history/update-$DATE.log 2>&1
bash "cd $ADDON; bash update_$ADDON_NAME.sh" >> ../history/update-$DATE.log 2>&1
bash ../addons/$ADDON_NAME/update_$ADDON_NAME.sh >> ../history/update-$DATE.log 2>&1
fi
fi
done
Expand Down

0 comments on commit 89548ca

Please sign in to comment.