| 
									
										
										
										
											2016-01-08 16:02:15 +01:00
										 |  |  | <?php | 
					
						
							| 
									
										
										
										
											2018-05-11 10:08:34 +02:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2017-10-21 08:40:00 +02:00
										 |  |  | /** | 
					
						
							|  |  |  |  * Kernel.php | 
					
						
							| 
									
										
										
										
											2020-01-23 20:35:02 +01:00
										 |  |  |  * Copyright (c) 2020 james@firefly-iii.org | 
					
						
							| 
									
										
										
										
											2017-10-21 08:40:00 +02:00
										 |  |  |  * | 
					
						
							| 
									
										
										
										
											2019-10-02 06:37:26 +02:00
										 |  |  |  * This file is part of Firefly III (https://github.com/firefly-iii). | 
					
						
							| 
									
										
										
										
											2017-10-21 08:40:00 +02:00
										 |  |  |  * | 
					
						
							| 
									
										
										
										
											2019-10-02 06:37:26 +02:00
										 |  |  |  * This program is free software: you can redistribute it and/or modify | 
					
						
							|  |  |  |  * it under the terms of the GNU Affero General Public License as | 
					
						
							|  |  |  |  * published by the Free Software Foundation, either version 3 of the | 
					
						
							|  |  |  |  * License, or (at your option) any later version. | 
					
						
							| 
									
										
										
										
											2017-10-21 08:40:00 +02:00
										 |  |  |  * | 
					
						
							| 
									
										
										
										
											2019-10-02 06:37:26 +02:00
										 |  |  |  * This program is distributed in the hope that it will be useful, | 
					
						
							| 
									
										
										
										
											2017-10-21 08:40:00 +02:00
										 |  |  |  * but WITHOUT ANY WARRANTY; without even the implied warranty of | 
					
						
							|  |  |  |  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the | 
					
						
							| 
									
										
										
										
											2019-10-02 06:37:26 +02:00
										 |  |  |  * GNU Affero General Public License for more details. | 
					
						
							| 
									
										
										
										
											2017-10-21 08:40:00 +02:00
										 |  |  |  * | 
					
						
							| 
									
										
										
										
											2019-10-02 06:37:26 +02:00
										 |  |  |  * You should have received a copy of the GNU Affero General Public License | 
					
						
							|  |  |  |  * along with this program.  If not, see <https://www.gnu.org/licenses/>. | 
					
						
							| 
									
										
										
										
											2017-10-21 08:40:00 +02:00
										 |  |  |  */ | 
					
						
							| 
									
										
										
										
											2017-09-14 17:40:02 +02:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2018-05-11 10:08:34 +02:00
										 |  |  | declare(strict_types=1); | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2016-01-08 16:02:15 +01:00
										 |  |  | namespace FireflyIII\Console; | 
					
						
							| 
									
										
										
										
											2015-02-06 04:39:52 +01:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2017-09-09 21:57:24 +02:00
										 |  |  | use Illuminate\Console\Scheduling\Schedule; | 
					
						
							| 
									
										
										
										
											2015-02-06 04:39:52 +01:00
										 |  |  | use Illuminate\Foundation\Console\Kernel as ConsoleKernel; | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2017-09-16 07:41:03 +02:00
										 |  |  | /** | 
					
						
							| 
									
										
										
										
											2018-06-24 13:23:08 +02:00
										 |  |  |  * File to make sure commands work. | 
					
						
							| 
									
										
										
										
											2017-09-16 07:41:03 +02:00
										 |  |  |  */ | 
					
						
							| 
									
										
										
										
											2015-02-11 07:35:10 +01:00
										 |  |  | class Kernel extends ConsoleKernel | 
					
						
							|  |  |  | { | 
					
						
							|  |  |  |     /** | 
					
						
							| 
									
										
										
										
											2017-09-14 17:40:02 +02:00
										 |  |  |      * Register the commands for the application. | 
					
						
							| 
									
										
										
										
											2015-02-11 07:35:10 +01:00
										 |  |  |      */ | 
					
						
							| 
									
										
										
										
											2018-06-24 13:23:08 +02:00
										 |  |  |     protected function commands(): void | 
					
						
							| 
									
										
										
										
											2017-09-09 21:57:24 +02:00
										 |  |  |     { | 
					
						
							| 
									
										
										
										
											2023-12-20 19:35:52 +01:00
										 |  |  |         $this->load(__DIR__.'/Commands'); | 
					
						
							| 
									
										
										
										
											2017-09-14 17:40:02 +02:00
										 |  |  | 
 | 
					
						
							|  |  |  |         require base_path('routes/console.php'); | 
					
						
							| 
									
										
										
										
											2017-09-09 21:57:24 +02:00
										 |  |  |     } | 
					
						
							| 
									
										
										
										
											2016-09-16 06:40:45 +02:00
										 |  |  | 
 | 
					
						
							|  |  |  |     /** | 
					
						
							| 
									
										
										
										
											2017-09-14 17:40:02 +02:00
										 |  |  |      * Define the application's command schedule. | 
					
						
							| 
									
										
										
										
											2016-09-16 06:40:45 +02:00
										 |  |  |      */ | 
					
						
							| 
									
										
										
										
											2018-06-22 18:42:23 +02:00
										 |  |  |     protected function schedule(Schedule $schedule): void | 
					
						
							| 
									
										
										
										
											2016-09-16 06:40:45 +02:00
										 |  |  |     { | 
					
						
							| 
									
										
										
										
											2018-08-18 14:08:28 +02:00
										 |  |  |         $schedule->call( | 
					
						
							| 
									
										
										
										
											2023-12-21 05:07:26 +01:00
										 |  |  |             static function (): void { | 
					
						
							| 
									
										
										
										
											2023-10-29 06:32:00 +01:00
										 |  |  |                 app('log')->error( | 
					
						
							| 
									
										
										
										
											2020-10-23 06:20:59 +02:00
										 |  |  |                     'Firefly III no longer users the Laravel scheduler to do cron jobs! Please read the instructions at https://docs.firefly-iii.org/' | 
					
						
							| 
									
										
										
										
											2019-02-13 17:38:41 +01:00
										 |  |  |                 ); | 
					
						
							| 
									
										
										
										
											2018-08-18 14:08:28 +02:00
										 |  |  |                 echo "\n"; | 
					
						
							|  |  |  |                 echo '------------'; | 
					
						
							|  |  |  |                 echo "\n"; | 
					
						
							|  |  |  |                 echo wordwrap('Firefly III no longer users the Laravel scheduler to do cron jobs! Please read the instructions here:'); | 
					
						
							|  |  |  |                 echo "\n"; | 
					
						
							| 
									
										
										
										
											2020-10-23 06:20:59 +02:00
										 |  |  |                 echo 'https://docs.firefly-iii.org/'; | 
					
						
							| 
									
										
										
										
											2018-08-18 14:08:28 +02:00
										 |  |  |                 echo "\n\n"; | 
					
						
							|  |  |  |                 echo 'Disable this cron job!'; | 
					
						
							|  |  |  |                 echo "\n"; | 
					
						
							|  |  |  |                 echo '------------'; | 
					
						
							|  |  |  |                 echo "\n"; | 
					
						
							|  |  |  |             } | 
					
						
							| 
									
										
										
										
											2019-12-27 11:05:27 +01:00
										 |  |  |         )->daily(); | 
					
						
							| 
									
										
										
										
											2016-09-16 06:40:45 +02:00
										 |  |  |     } | 
					
						
							| 
									
										
										
										
											2015-02-06 04:39:52 +01:00
										 |  |  | } |