diff --git a/scripts/create-release.sh b/scripts/create-release.sh index 58cc1c5858..83f96d3191 100755 --- a/scripts/create-release.sh +++ b/scripts/create-release.sh @@ -240,6 +240,7 @@ ensure_local_branch $branch VERSION_FILE=libraries/classes/Version.php +# Keep in sync with update-po script fetchReleaseFromFile() { php -r "define('VERSION_SUFFIX', ''); require_once('libraries/classes/Version.php'); echo \PhpMyAdmin\Version::VERSION;" } diff --git a/scripts/set-version.sh b/scripts/set-version.sh index 8d79a3414a..7ae906bf5c 100755 --- a/scripts/set-version.sh +++ b/scripts/set-version.sh @@ -57,7 +57,7 @@ echo "Changing from ${oldVersion} to ${newVersion}..." oldVersion=${oldVersion//./\.} newVersion=${newVersion//./\.} -for f in README doc/conf.py libraries/classes/Config.php package.json +for f in README doc/conf.py package.json do if ! grep --quiet "${oldVersion}" "${dir}${f}" then @@ -71,4 +71,5 @@ done echo echo "Next, you need to manually edit ChangeLog to manually change the version number and set the release date, and verify the changes with 'git diff'." -echo "Suggested commit message: Prepare for version ${newVersion}" \ No newline at end of file +echo "You will probably want to call: \"./scripts/console set-version ${newVersion}\" afterwards" +echo "Suggested commit message: Prepare for version ${newVersion}" diff --git a/scripts/update-po b/scripts/update-po index 4075f96d90..afa88aa45d 100755 --- a/scripts/update-po +++ b/scripts/update-po @@ -43,7 +43,12 @@ php scripts/fix-po-twig # Remote twig templates rm -rf twig-templates/ -ver=`sed -n "/PMA_VERSION', '/ s/.*PMA_VERSION', '\(.*\)'.*/\1/p" libraries/classes/Config.php` +# Keep in sync with create-release.sh +fetchReleaseFromFile() { + php -r "define('VERSION_SUFFIX', ''); require_once('libraries/classes/Version.php'); echo \PhpMyAdmin\Version::VERSION;" +} + +ver="$(fetchReleaseFromFile)" sed -i.~ ' s/SOME DESCRIPTIVE TITLE/phpMyAdmin translation/;