From ce80179953ed68ba05afa2a81ac56615db9383f1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Wed, 1 Feb 2023 09:54:53 +0100 Subject: [PATCH] Fix --- scripts/install | 4 ++-- scripts/upgrade | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/scripts/install b/scripts/install index b6375d8..07be1c0 100755 --- a/scripts/install +++ b/scripts/install @@ -159,8 +159,8 @@ pushd "$final_path" ynh_exec_warn_less ynh_exec_as $app php$phpversion artisan passport:client --password -n > key.txt mobile_id=$( cd $final_path && tail -2 key.txt | head -1 | cut -c 12- ) mobile_key=$( cd $final_path && tail -1 key.txt | cut -c 16- ) - ynh_replace_string --match_string="__MOBILE_ID__" --replace_string="$mobile_id" --target_file="$final_path/.env" - ynh_replace_string --match_string="__MOBILE_KEY__" --replace_string="$mobile_key" --target_file="$final_path/.env" + ynh_replace_string --match_string="mobile_id" --replace_string="$mobile_id" --target_file="$final_path/.env" + ynh_replace_string --match_string="mobile_key" --replace_string="$mobile_key" --target_file="$final_path/.env" ynh_app_setting_set --app=$app --key=mobile_id --value=$mobile_id ynh_app_setting_set --app=$app --key=mobile_key --value=$mobile_key ynh_secure_remove --file="$final_path/key.txt" diff --git a/scripts/upgrade b/scripts/upgrade index 83968b2..4e1e95d 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -176,16 +176,16 @@ popd if [ -f $final_path/storage/oauth-private.key ]; then mobile_id=$(ynh_app_setting_get --app=$app --key=mobile_id) mobile_key=$(ynh_app_setting_get --app=$app --key=mobile_key) - ynh_replace_string --match_string="__MOBILE_ID__" --replace_string="$mobile_id" --target_file="$final_path/.env" - ynh_replace_string --match_string="__MOBILE_KEY__" --replace_string="$mobile_key" --target_file="$final_path/.env" + ynh_replace_string --match_string="mobile_id" --replace_string="$mobile_id" --target_file="$final_path/.env" + ynh_replace_string --match_string="mobile_key" --replace_string="$mobile_key" --target_file="$final_path/.env" else pushd "$final_path" ynh_exec_warn_less ynh_exec_as $app php$phpversion artisan passport:keys ynh_exec_warn_less ynh_exec_as $app php$phpversion artisan passport:client --password -n > key.txt mobile_id=$( tail -2 key.txt | head -1 | cut -c 12- ) mobile_key=$( tail -1 key.txt | cut -c 16- ) - ynh_replace_string --match_string="__MOBILE_ID__" --replace_string="$mobile_id" --target_file="$final_path/.env" - ynh_replace_string --match_string="__MOBILE_KEY__" --replace_string="$mobile_key" --target_file="$final_path/.env" + ynh_replace_string --match_string="mobile_id" --replace_string="$mobile_id" --target_file="$final_path/.env" + ynh_replace_string --match_string="mobile_key" --replace_string="$mobile_key" --target_file="$final_path/.env" ynh_app_setting_set --app=$app --key=mobile_id --value=$mobile_id ynh_app_setting_set --app=$app --key=mobile_key --value=$mobile_key ynh_secure_remove --file="$final_path/key.txt"