Skip to content

Firefly III: a personal finances manager

New time things

Sander Dorigo2d0efa17b152
diff --git a/app/Console/Commands/Correction/CorrectsDatabase.php b/app/Console/Commands/Correction/CorrectsDatabase.php
index 8637bf0253..3fd129091e 100644
--- a/app/Console/Commands/Correction/CorrectsDatabase.php
+++ b/app/Console/Commands/Correction/CorrectsDatabase.php
@@ -82,11 +82,13 @@ class CorrectsDatabase extends Command
'firefly-iii:report-integrity',
];
foreach ($commands as $command) {
- $this->friendlyLine(sprintf('Now executing command "%s"', $command));
+ $moment = date('H:i:s');
+ $this->friendlyLine(sprintf('[%s] Now executing command "%s"',$moment, $command));
$time = microtime(true);
$this->call($command);
$time = microtime(true) - $time;
- $this->friendlyLine(sprintf('Command %s took %.4f seconds.', $command, $time));
+ $moment = date('H:i:s');
+ $this->friendlyLine(sprintf('[%s] Command %s took %.4f seconds.', $moment, $command, $time));
}
return 0;
diff --git a/app/Console/Commands/Integrity/ReportsIntegrity.php b/app/Console/Commands/Integrity/ReportsIntegrity.php
index 8a74112398..8de3e1ba61 100644
--- a/app/Console/Commands/Integrity/ReportsIntegrity.php
+++ b/app/Console/Commands/Integrity/ReportsIntegrity.php
@@ -47,11 +47,13 @@ class ReportsIntegrity extends Command
}
$commands = ['integrity:empty-objects', 'integrity:total-sums', 'integrity:file-permissions'];
foreach ($commands as $command) {
- $this->friendlyLine(sprintf('Now executing command %s', $command));
+ $moment = date('H:i:s');
+ $this->friendlyLine(sprintf('[%s] Now executing command %s',$moment, $command));
$time = microtime(true);
$this->call($command);
$time = microtime(true) - $time;
- $this->friendlyLine(sprintf('Command %s took %.4f seconds.', $command, $time));
+ $moment = date('H:i:s');
+ $this->friendlyLine(sprintf('[%s] Command %s took %.4f seconds.', $moment, $command, $time));
}
return 0;
diff --git a/app/Console/Commands/Upgrade/UpgradesDatabase.php b/app/Console/Commands/Upgrade/UpgradesDatabase.php
index e3e1efb2e5..ef90ef1878 100644
--- a/app/Console/Commands/Upgrade/UpgradesDatabase.php
+++ b/app/Console/Commands/Upgrade/UpgradesDatabase.php
@@ -85,11 +85,13 @@ class UpgradesDatabase extends Command
$args = ['--force' => true];
}
foreach ($commands as $command) {
- $this->friendlyLine(sprintf('Now executing command %s', $command));
+ $moment = date('H:i:s');
+ $this->friendlyLine(sprintf('[%s] Now executing command %s', $moment, $command));
$time = microtime(true);
$this->call($command, $args);
$time = round(microtime(true) - $time, 2);
- $this->friendlyLine(sprintf('Command %s took %.4f seconds.', $command, $time));
+ $moment = date('H:i:s');
+ $this->friendlyLine(sprintf('[%s] Command %s took %.4f seconds.', $moment, $command, $time));
}
// index will set FF3 version.
AppConfiguration::set('ff3_build_time', (int) config('firefly.build_time'));