From fc39fd74c63387dfafa3006468d4ed8d3054fc90 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Mon, 15 Aug 2022 17:55:40 +0200 Subject: [PATCH] Update upgrade --- scripts/upgrade | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index ff534a1..3046686 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -82,20 +82,8 @@ if [ "$upgrade_type" == "UPGRADE_APP" ] then ynh_script_progression --message="Upgrading source files..." --weight=3 - # Create a temporary directory - tmpdir="$(mktemp -d)" - - # Backup the config file in the temp dir - cp -a "$final_path/searx/settings.yml" "$tmpdir/settings.yml" - # Download, check integrity, uncompress and patch the source from app.src - ynh_setup_source --dest_dir="$final_path" - - # Copy the admin saved settings from tmp directory to final path - cp -a "$tmpdir/settings.yml" "$final_path/searx/settings.yml" - - # Remove the tmp directory securely - ynh_secure_remove --file="$tmpdir" + ynh_setup_source --dest_dir="$final_path" --keep="searx/settings.yml" fi #=================================================