From 07ab5640a63fcbf3f0ac1b2e5df745efff613467 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ji=C5=99=C3=AD=20Klime=C5=A1?= Date: Fri, 15 Mar 2019 12:52:15 +0100 Subject: [PATCH] upgrade: temporary fix for convert-timezone script from 0.8.1 kimai release This commit should be removed when a fixed kimai will be released (presumably as 0.8.2). see: https://github.com/kevinpapst/kimai2/pull/637 --- scripts/upgrade | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/upgrade b/scripts/upgrade index 24e608c..052f3eb 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -156,6 +156,10 @@ cd $final_path && sudo /usr/bin/php7.2 bin/console cache:clear --env=prod cd $final_path && sudo /usr/bin/php7.2 bin/console cache:warmup --env=prod cd $final_path && sudo /usr/bin/php7.2 bin/console doctrine:migrations:migrate -n +# convert-timezone script has a problem running non-interactively (-n) on 0.8.1 +# fix it here +sed -i "s/, \$amount));/, \$amount), 'y');/" /var/www/$app/src/Command/ConvertTimezoneCommand.php + # call convert-timezone script when upgrading from < 0.8 verions # fixes timezone issue: https://github.com/kevinpapst/kimai2/pull/372 if `dpkg --compare-versions $old_ver "lt" "0.8"`