From a4faf5c6f034051b3d3d19e1be4a6c73925dbedb Mon Sep 17 00:00:00 2001 From: Tagada <36127788+Tagadda@users.noreply.github.com> Date: Mon, 4 Apr 2022 20:21:11 +0200 Subject: [PATCH 1/3] Apply suggestions from code review --- scripts/change_url | 2 +- scripts/install | 2 +- scripts/remove | 2 +- scripts/restore | 2 +- scripts/upgrade | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/scripts/change_url b/scripts/change_url index 720ae93..7eba06d 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -65,7 +65,7 @@ fi #================================================= # MODIFY URL IN NGINX CONF #================================================= -ynh_script_progression --message="Updating NGINX web server configuration..." --weight=1 +ynh_script_progression --message="Updating NGINX web server configuration..." --weight=3 nginx_conf_path=/etc/nginx/conf.d/$old_domain.d/$app.conf diff --git a/scripts/install b/scripts/install index 048ea77..e18c3ef 100644 --- a/scripts/install +++ b/scripts/install @@ -87,7 +87,7 @@ ynh_system_user_create --username=$app --home_dir="$final_path" #================================================= # DOWNLOAD, CHECK AND UNPACK SOURCE #================================================= -ynh_script_progression --message="Setting up source files..." --weight=1 +ynh_script_progression --message="Setting up source files..." --weight=4 ynh_app_setting_set --app=$app --key=final_path --value=$final_path # Download, check integrity, uncompress and patch the source from app.src diff --git a/scripts/remove b/scripts/remove index 7c6361b..93d6724 100644 --- a/scripts/remove +++ b/scripts/remove @@ -28,7 +28,7 @@ final_path=$(ynh_app_setting_get --app=$app --key=final_path) #================================================= # REMOVE APP MAIN DIR #================================================= -ynh_script_progression --message="Removing app main directory..." --weight=1 +ynh_script_progression --message="Removing app main directory..." --weight=3 # Remove the app directory securely ynh_secure_remove --file="$final_path" diff --git a/scripts/restore b/scripts/restore index 5f158ff..27f9724 100644 --- a/scripts/restore +++ b/scripts/restore @@ -60,7 +60,7 @@ ynh_system_user_create --username=$app --home_dir="$final_path" #================================================= # RESTORE THE APP MAIN DIR #================================================= -ynh_script_progression --message="Restoring the app main directory..." --weight=1 +ynh_script_progression --message="Restoring the app main directory..." --weight=4 ynh_restore_file --origin_path="$final_path" diff --git a/scripts/upgrade b/scripts/upgrade index 93e5891..e21ca0f 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -90,7 +90,7 @@ ynh_system_user_create --username=$app --home_dir="$final_path" if [ "$upgrade_type" == "UPGRADE_APP" ] then - ynh_script_progression --message="Upgrading source files..." --weight=1 + ynh_script_progression --message="Upgrading source files..." --weight=4 # Download, check integrity, uncompress and patch the source from app.src ynh_setup_source --dest_dir="$final_path" From ed091b498073b547cb939d4424c3c9d7dcbbd143 Mon Sep 17 00:00:00 2001 From: Tagada <36127788+Tagadda@users.noreply.github.com> Date: Mon, 4 Apr 2022 20:22:57 +0200 Subject: [PATCH 2/3] Update scripts/remove --- scripts/remove | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/scripts/remove b/scripts/remove index 93d6724..bcbd72a 100644 --- a/scripts/remove +++ b/scripts/remove @@ -60,12 +60,9 @@ ynh_remove_app_dependencies #================================================= # SPECIFIC REMOVE #================================================= -# REMOVE VARIOUS FILES +# ... #================================================= -ynh_script_progression --message="Removing various files..." --weight=1 -# Remove a directory securely -ynh_secure_remove --file="/etc/$app" #================================================= # GENERIC FINALIZATION From 378990cb6dfd87958cba7d30dfb6e9647ad1785d Mon Sep 17 00:00:00 2001 From: Tagada <36127788+Tagadda@users.noreply.github.com> Date: Wed, 4 May 2022 01:21:56 +0200 Subject: [PATCH 3/3] Update scripts/remove --- scripts/remove | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/remove b/scripts/remove index bcbd72a..92c3940 100644 --- a/scripts/remove +++ b/scripts/remove @@ -31,7 +31,7 @@ final_path=$(ynh_app_setting_get --app=$app --key=final_path) ynh_script_progression --message="Removing app main directory..." --weight=3 # Remove the app directory securely -ynh_secure_remove --file="$final_path" +ynh_secure_remove --file="$final_path/_h5ai" #================================================= # REMOVE NGINX CONFIGURATION