From cb3134ba697536145fd4c7e746d7172000a453dc Mon Sep 17 00:00:00 2001 From: Gofannon <17145502+Gofannon@users.noreply.github.com> Date: Sun, 10 Jul 2022 16:28:55 +0200 Subject: [PATCH 1/3] document php version choice with "YNH_PHP_VERSION" --- scripts/_common.sh | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index 7e55ac0..252cc01 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -3,9 +3,22 @@ #================================================= # COMMON VARIABLES #================================================= +# PHP APP SPECIFIC +#================================================= +# PHP version used by the application can be changed here +# YunoHost uses a "default php" version depending of its version +## YunoHost version "11.X" => php 7.4 +## YunoHost version "4.X" => php 7.3 +# +# This behaviour can be overrided by setting the variable +#YNH_PHP_VERSION=7.3 +#YNH_PHP_VERSION=7.4 +#YNH_PHP_VERSION=8.0 +# For more information, see the "php helper": https://github.com/YunoHost/yunohost/blob/dev/helpers/php#L3-L6= +# Or this php package: https://github.com/YunoHost-Apps/grav_ynh/blob/master/scripts/_common.sh -# dependencies used by the app -pkg_dependencies="deb1 deb2 php$YNH_DEFAULT_PHP_VERSION-deb1 php$YNH_DEFAULT_PHP_VERSION-deb2" +# dependencies used by the app (must be on a single line) +pkg_dependencies="deb1 deb2 php$YNH_PHP_VERSION-deb1 php$YNH_PHP_VERSION-deb2" #================================================= # PERSONAL HELPERS From 46b25cf8f5069935237552917c6816e3601bd971 Mon Sep 17 00:00:00 2001 From: yalh76 Date: Thu, 4 Aug 2022 19:18:10 +0200 Subject: [PATCH 2/3] Update scripts/_common.sh Co-authored-by: tituspijean --- scripts/_common.sh | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index 252cc01..fea6284 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -5,17 +5,20 @@ #================================================= # PHP APP SPECIFIC #================================================= -# PHP version used by the application can be changed here -# YunoHost uses a "default php" version depending of its version -## YunoHost version "11.X" => php 7.4 -## YunoHost version "4.X" => php 7.3 +# Depending on its version, YunoHost uses different default PHP version: +## YunoHost version "11.X" => PHP 7.4 +## YunoHost version "4.X" => PHP 7.3 # -# This behaviour can be overrided by setting the variable +# This behaviour can be overridden by setting the YNH_PHP_VERSION variable #YNH_PHP_VERSION=7.3 #YNH_PHP_VERSION=7.4 #YNH_PHP_VERSION=8.0 -# For more information, see the "php helper": https://github.com/YunoHost/yunohost/blob/dev/helpers/php#L3-L6= -# Or this php package: https://github.com/YunoHost-Apps/grav_ynh/blob/master/scripts/_common.sh +# For more information, see the PHP application helper: https://github.com/YunoHost/yunohost/blob/dev/helpers/php#L3-L6 +# Or this app package depending on PHP: https://github.com/YunoHost-Apps/grav_ynh/blob/master/scripts/_common.sh +# PHP dependencies used by the app (must be on a single line) +#php_dependencies="php$YNH_PHP_VERSION-deb1 php$YNH_PHP_VERSION-deb2" +# or, if you do not need a custom YNH_PHP_VERSION: +php_dependencies="php$YNH_DEFAULT_PHP_VERSION-deb1 php$YNH_DEFAULT_PHP_VERSION-deb2" # dependencies used by the app (must be on a single line) pkg_dependencies="deb1 deb2 php$YNH_PHP_VERSION-deb1 php$YNH_PHP_VERSION-deb2" From b5ff61c826a418df8a06f73ebc7f7c3a61b40900 Mon Sep 17 00:00:00 2001 From: yalh76 Date: Thu, 4 Aug 2022 19:18:17 +0200 Subject: [PATCH 3/3] Update scripts/_common.sh Co-authored-by: tituspijean --- scripts/_common.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index fea6284..04b61bb 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -21,7 +21,7 @@ php_dependencies="php$YNH_DEFAULT_PHP_VERSION-deb1 php$YNH_DEFAULT_PHP_VERSION-deb2" # dependencies used by the app (must be on a single line) -pkg_dependencies="deb1 deb2 php$YNH_PHP_VERSION-deb1 php$YNH_PHP_VERSION-deb2" +pkg_dependencies="deb1 deb2 $php_dependencies" #================================================= # PERSONAL HELPERS