Firefly III: a personal finances manager
PHP accountingbudgetbudgetingbudgetscash-flowcashflowcredit-carddockerexpensesfinancefinancesfinanciallinuxmoneypaycheckpersonal-financephpphp7
New: upgrade instructions when installing or upgrading composer packages.
James Cole1b3198c143ab
diff --git a/app/Console/Commands/UpgradeFireflyInstructions.php b/app/Console/Commands/UpgradeFireflyInstructions.phpnew file mode 100644index 0000000000..4c11f648a0--- /dev/null+++ b/app/Console/Commands/UpgradeFireflyInstructions.php@@ -0,0 +1,67 @@+<?php++namespace FireflyIII\Console\Commands;++use Config;+use Illuminate\Console\Command;++/**+ * Class UpgradeFireflyInstructions+ *+ * @package FireflyIII\Console\Commands+ */+class UpgradeFireflyInstructions extends Command+{+ /**+ * The name and signature of the console command.+ *+ * @var string+ */+ protected $signature = 'firefly:upgrade-instructions';++ /**+ * The console command description.+ *+ * @var string+ */+ protected $description = 'Command description';++ /**+ * Create a new command instance.+ *+ * @return void+ */+ public function __construct()+ {+ parent::__construct();+ }++ /**+ * Execute the console command.+ *+ * @return mixed+ */+ public function handle()+ {+ //+ $version = Config::get('firefly.version');+ $config = Config::get('upgrade.text');+ $text = isset($config[$version]) ? $config[$version] : null;++ $this->line('+------------------------------------------------------------------------------+');+ $this->line('');++ if (is_null($text)) {+ $this->line('Thank you for installing Firefly III, v' . $version);+ $this->info('There are no extra upgrade instructions.');+ $this->line('Firefly III should be ready for use.');+ } else {+ $this->line('Thank you for installing Firefly III, v' . $version);+ $this->line('Please follow these upgrade instructions carefully.');+ $this->info(wordwrap($text));+ }++ $this->line('');+ $this->line('+------------------------------------------------------------------------------+');+ }+}diff --git a/app/Console/Kernel.php b/app/Console/Kernel.phpindex 4cc39c0df9..386fd469c7 100755--- a/app/Console/Kernel.php+++ b/app/Console/Kernel.php@@ -9,6 +9,7 @@namespace FireflyIII\Console;+use FireflyIII\Console\Commands\UpgradeFireflyInstructions;use Illuminate\Console\Scheduling\Schedule;use Illuminate\Foundation\Console\Kernel as ConsoleKernel;@@ -26,6 +27,7 @@ class Kernel extends ConsoleKernel*/protected $commands= [+ UpgradeFireflyInstructions::class];/**diff --git a/config/firefly.php b/config/firefly.phpindex 952f9463e6..f37b62ce98 100644--- a/config/firefly.php+++ b/config/firefly.php@@ -2,7 +2,7 @@return ['chart' => 'chartjs',- 'version' => '3.6.1',+ 'version' => '3.7.0','index_periods' => ['1D', '1W', '1M', '3M', '6M', '1Y', 'custom'],'budget_periods' => ['daily', 'weekly', 'monthly', 'quarterly', 'half-year', 'yearly'],'csv_import_enabled' => true,diff --git a/config/upgrade.php b/config/upgrade.phpnew file mode 100644index 0000000000..be8b331d37--- /dev/null+++ b/config/upgrade.php@@ -0,0 +1,15 @@+<?php+/**+ * upgrade.php+ * Copyright (C) 2016 Sander Dorigo+ *+ * This software may be modified and distributed under the terms+ * of the MIT license. See the LICENSE file for details.+ */+++return [+ 'text' => [+ '3.7.0' => 'Because of the upgrade to Laravel 5.2, several manual changes must be made to your Firefly III installation. ' .+ 'Please follow the instructions on the following page: https://github.com/JC5/firefly-iii/wiki/Upgrade-to-3.7.0'],+];\ No newline at end of file