From a2eb3c5512a1252e7cea131e3a32dc1c5d52bcde Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?F=C3=A9lix=20Pi=C3=A9dallu?= Date: Thu, 11 Jan 2024 00:46:59 +0100 Subject: [PATCH] full_replace ynh_setup source upgrade --- scripts/upgrade | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 16b8a87..41a9b92 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -17,22 +17,21 @@ upgrade_type=$(ynh_check_app_version_changed) # DOWNLOAD, CHECK AND UNPACK SOURCE #================================================= -if [ "$upgrade_type" == "UPGRADE_APP" ] -then - ynh_script_progression --message="Upgrading source files..." --weight=1 +if [ "$upgrade_type" == "UPGRADE_APP" ]; then + ynh_script_progression --message="Upgrading source files..." --weight=1 - ynh_setup_source --dest_dir="$install_dir/source" - chown -R $app:www-data "$install_dir" + ynh_setup_source --dest_dir="$install_dir/source" --full_replace=1 + chown -R $app:www-data "$install_dir" - ynh_script_progression --message="Installing NodeJS..." --weight=20 + ynh_script_progression --message="Installing NodeJS..." --weight=20 - # Install Nodejs - ynh_exec_warn_less ynh_install_nodejs --nodejs_version=$nodejs_version + # Install Nodejs + ynh_exec_warn_less ynh_install_nodejs --nodejs_version=$nodejs_version - ynh_script_progression --message="Building Jellyfin Vue... (this will take some time and resources!)" --weight=24 + ynh_script_progression --message="Building Jellyfin Vue... (this will take some time and resources!)" --weight=24 - _patch_config_json "$install_dir/source" - _npm_build_install "$install_dir/source" "$install_dir/www" "$path/" + _patch_config_json "$install_dir/source" + _npm_build_install "$install_dir/source" "$install_dir/www" "$path/" fi chown -R $app:www-data "$install_dir"