cherrypulp /
laravel-package-generator
| 1 | <?php |
||
| 2 | |||
| 3 | namespace Cherrypulp\LaravelPackageGenerator; |
||
| 4 | |||
| 5 | use Cherrypulp\LaravelPackageGenerator\Commands\PackageNew; |
||
| 6 | use Cherrypulp\LaravelPackageGenerator\Commands\PackageRemove; |
||
| 7 | |||
| 8 | class ServiceProvider extends \Illuminate\Support\ServiceProvider |
||
| 9 | { |
||
| 10 | const CONFIG_PATH = __DIR__.'/../config/laravel-package-generator.php'; |
||
| 11 | |||
| 12 | public function boot() |
||
| 13 | { |
||
| 14 | $this->publishes([ |
||
| 15 | self::CONFIG_PATH => config_path('laravel-package-generator.php'), |
||
|
0 ignored issues
–
show
Bug
introduced
by
Loading history...
|
|||
| 16 | ], 'config'); |
||
| 17 | |||
| 18 | if ($this->app->runningInConsole()) { |
||
| 19 | |||
| 20 | |||
| 21 | |||
| 22 | $this->commands([ |
||
| 23 | PackageNew::class, |
||
| 24 | PackageRemove::class, |
||
| 25 | ]); |
||
| 26 | } |
||
| 27 | } |
||
| 28 | |||
| 29 | public function register() |
||
| 30 | { |
||
| 31 | $this->mergeConfigFrom( |
||
| 32 | self::CONFIG_PATH, |
||
| 33 | 'laravel-package-generator' |
||
| 34 | ); |
||
| 35 | } |
||
| 36 | } |
||
| 37 |