diff --git a/scripts/upgrade b/scripts/upgrade index fc4a83b..a89f932 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -41,6 +41,12 @@ if [[ -n "${document_path:-}" ]]; then ynh_app_setting_set --app="$app" --key=document_dir --value="$document_dir" fi +# document dir has moved from html_path to data_dir, so set the variable accordingly +if [[ ${document_dir} == ${html_path}* ]]; then + document_dir=$data_dir/docs + ynh_app_setting_set --app="$app" --key=document_dir --value="$document_dir" +fi + if [[ -n "${html_path:-}" ]]; then # Migrate html_path to data_dir mv "$html_path/index.html" "$html_path/docs" "$data_dir" diff --git a/tests.toml b/tests.toml index 8489737..77f10a9 100644 --- a/tests.toml +++ b/tests.toml @@ -10,3 +10,5 @@ test_format = 1.0 # ------------------------------- test_upgrade_from.7852cc4bf44ff20ee51fe35f3f53dc105e0f6d79.name= "2023-01-07 - Added Ssh support for dev." + test_upgrade_from.e89eebdac9f59202202d07972e274ebe6fc7c51c.name= "Before Manifest v2." + \ No newline at end of file