From d574ff706a1a68a554a3e148e28dd116630e6472 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?F=C3=A9lix=20Pi=C3=A9dallu?= Date: Fri, 23 Feb 2024 22:45:07 +0100 Subject: [PATCH] Cleanup upgrade --- scripts/upgrade | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 80c1386..6d754e5 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -8,28 +8,19 @@ source _common.sh source /usr/share/yunohost/helpers -#================================================= -# CHECK VERSION -#================================================= -upgrade_type=$(ynh_check_app_version_changed) - -#================================================= -# STANDARD UPGRADE STEPS #================================================= # ENSURE DOWNWARD COMPATIBILITY #================================================= -ynh_script_progression --message="Ensuring downward compatibility..." --weight=1 +# ynh_script_progression --message="Ensuring downward compatibility..." --weight=1 #================================================= # DOWNLOAD, CHECK AND UNPACK SOURCE #================================================= +ynh_script_progression --message="Upgrading source files..." -if [ "$upgrade_type" == "UPGRADE_APP" ] -then - ynh_setup_source --dest_dir="$install_dir" --keep=config.php - myynh_clean_source -fi +ynh_setup_source --dest_dir="$install_dir" --full_replace=1 --keep=config.php +myynh_clean_source chmod -R o-rwx "$install_dir" chown -R "$app:www-data" "$install_dir"