1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/nextcloud_ynh.git synced 2024-09-03 19:55:57 +02:00

migrate system_addressbook_exposed to boolean, fix upgrade test

This commit is contained in:
Kayou 2024-07-29 11:22:01 +02:00 committed by GitHub
parent a3173b76a1
commit 7f40b5a17b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 10 additions and 0 deletions

View file

@ -10,6 +10,15 @@ upgrade_type=$(ynh_check_app_version_changed)
#================================================= #=================================================
ynh_script_progression --message="Ensuring downward compatibility..." ynh_script_progression --message="Ensuring downward compatibility..."
# Fix system_addressbook_exposed as a boolean
if [ "${system_addressbook_exposed,,}" = "yes" ]; then
ynh_app_setting_set --app=$app --key=system_addressbook_exposed --value=1
system_addressbook_exposed=1
elif [ "${system_addressbook_exposed,,}" = "no" ]; then
ynh_app_setting_set --app=$app --key=system_addressbook_exposed --value=0
system_addressbook_exposed=0
fi
# Remove the option backup_core_only if it's in the settings.yml file # Remove the option backup_core_only if it's in the settings.yml file
ynh_app_setting_delete --app=$app --key=backup_core_only ynh_app_setting_delete --app=$app --key=backup_core_only

View file

@ -10,3 +10,4 @@ test_format = 1.0
test_upgrade_from.caf917f3.name = "Upgrade from 26.0.2" test_upgrade_from.caf917f3.name = "Upgrade from 26.0.2"
test_upgrade_from.9c6d1eea.name = "Upgrade from 27.1.4" test_upgrade_from.9c6d1eea.name = "Upgrade from 27.1.4"
test_upgrade_from.e9f82ab7.name = "Upgrade from 28.0.6" test_upgrade_from.e9f82ab7.name = "Upgrade from 28.0.6"
test_upgrade_from.e9f82ab7.args.system_addressbook_exposed = "yes"