mirror of
https://github.com/YunoHost-Apps/framaforms_ynh.git
synced 2024-09-03 18:36:12 +02:00
Change upstream to Yakforms, handle migration.
This commit is contained in:
parent
382f16cadf
commit
512f1e558d
3 changed files with 35 additions and 1 deletions
0
conf/extra_php-fpm.conf
Normal file
0
conf/extra_php-fpm.conf
Normal file
|
@ -13,7 +13,7 @@ maintainers = []
|
|||
|
||||
[upstream]
|
||||
license = "GPL-2.0-only"
|
||||
website = "https://framaforms.org"
|
||||
website = "https://yakforms.org"
|
||||
code = "https://framagit.org/yakforms/yakforms"
|
||||
fund = "https://soutenir.framasoft.org"
|
||||
|
||||
|
|
|
@ -12,6 +12,25 @@ source /usr/share/yunohost/helpers
|
|||
#=================================================
|
||||
# ynh_script_progression --message="Ensuring downward compatibility..." --weight=1
|
||||
|
||||
#=================================================
|
||||
# Framaforms 2 Yakforms Backup
|
||||
#=================================================
|
||||
upgrade_to_yakforms=true
|
||||
|
||||
if [ "$upgrade_to_yakforms" = false ]; then
|
||||
pushd "$install_dir"
|
||||
ynh_exec_as "$app" env "PATH=$PATH" "php$phpversion" framaforms2yakforms.php backup
|
||||
_ynh_exec_with_drush_php drush "@$app" dis framaforms
|
||||
_ynh_exec_with_drush_php drush "@$app" pm-uninstall framaforms
|
||||
_ynh_exec_with_drush_php drush "@$app" dis framaforms_share_results
|
||||
_ynh_exec_with_drush_php drush "@$app" pm-uninstall framaforms_share_results
|
||||
_ynh_exec_with_drush_php drush "@$app" dis framaforms_public_results
|
||||
_ynh_exec_with_drush_php drush "@$app" pm-uninstall framaforms_public_results
|
||||
_ynh_exec_with_drush_php drush "@$app" dis framaforms_spam
|
||||
_ynh_exec_with_drush_php drush "@$app" pm-uninstall framaforms_spam
|
||||
popd
|
||||
fi
|
||||
|
||||
#=================================================
|
||||
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
||||
#=================================================
|
||||
|
@ -33,6 +52,21 @@ ynh_script_progression --message="Upgrading Composer..." --weight=3
|
|||
|
||||
ynh_install_composer --phpversion="$phpversion" --workdir="$install_dir/.composer"
|
||||
|
||||
#=================================================
|
||||
# Framaforms 2 Yakforms Restore
|
||||
#=================================================
|
||||
|
||||
if [ "$upgrade_to_yakforms" = true ]; then
|
||||
pushd "$install_dir"
|
||||
_ynh_exec_with_drush_php drush "@$app" en yakforms
|
||||
_ynh_exec_with_drush_php drush "@$app" dis yakforms_share_results
|
||||
_ynh_exec_with_drush_php drush "@$app" dis yakforms_public_results
|
||||
_ynh_exec_with_drush_php drush "@$app" dis yakforms_spam
|
||||
ynh_exec_as "$app" env "PATH=$PATH" "php$phpversion" framaforms2yakforms.php restore
|
||||
ynh_exec_as "$app" env "PATH=$PATH" "php$phpversion" framaforms2yakforms.php clean
|
||||
popd
|
||||
fi
|
||||
|
||||
#=================================================
|
||||
# UPGRADE DRUPAL
|
||||
#=================================================
|
||||
|
|
Loading…
Reference in a new issue