From 6866247427eb8d587ed6e24a89a6b1933f08bddd Mon Sep 17 00:00:00 2001 From: Martin Renvoize Date: Thu, 20 Feb 2020 14:30:29 +0000 Subject: [PATCH] Bug 24696: Add completion times to updatedatabase This patch adds completion times to the print statements in updateadatabase.pl. Signed-off-by: Bernardo Gonzalez Kriegel Tested on top of Bug 24131 Work Ok, no errors. Signed-off-by: Kyle M Hall --- installer/data/mysql/updatedatabase.pl | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index bcb617ffed..d7d900aea8 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -21257,21 +21257,23 @@ sub NewVersion { $descriptions = [ $descriptions ]; } my $first = 1; + my ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime(time); + my $time = sprintf ( "%02d:%02d:%02d", $hour,$min,$sec); for my $description ( @$descriptions ) { if ( @$descriptions > 1 ) { if ( $first ) { unless ( $bug_number ) { - say sprintf "Upgrade to %s done: %s", $DBversion, $description + say sprintf "Upgrade to %s done [%s]: %s", $DBversion, $time, $description; } else { - say sprintf "Upgrade to %s done: Bug %5s - %s", $DBversion, $bug_number, $description; + say sprintf "Upgrade to %s done [%s]: Bug %5s - %s", $DBversion, $time, $bug_number, $description; } } - say sprintf "\t\t\t\t\t- %s", $description + say sprintf "\t\t\t\t\t- %s", $description; } else { unless ( $bug_number ) { - say sprintf "Upgrade to %s done: %s", $DBversion, $description; + say sprintf "Upgrade to %s done [%s]: %s", $DBversion, $time, $description; } else { - say sprintf "Upgrade to %s done: Bug %5s - %s", $DBversion, $bug_number, $description; + say sprintf "Upgrade to %s done [%s]: Bug %5s - %s", $DBversion, $time, $bug_number, $description; } } $first = 0; -- 2.21.1 (Apple Git-122.3)