-
Notifications
You must be signed in to change notification settings - Fork 1
/
ArtisanServiceProvider.php
42 lines (36 loc) · 1.09 KB
/
ArtisanServiceProvider.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
<?php
namespace clentfort\LaravelFindJsLocalizations;
use Illuminate\Support\ServiceProvider;
use File;
class ArtisanServiceProvider extends ServiceProvider
{
/**
* Bootstrap the application services.
*/
public function boot()
{
$configSourcePath = PathHelper::join(__DIR__, 'config.php');
$configTargetPath = config_path('laravel-find-js-localizations.php');
$this->publishes([$configSourcePath => $configTargetPath]);
}
/**
* Register the application services.
*/
public function register()
{
$this->mergeConfigFrom(
PathHelper::join(__DIR__, 'config.php'),
'laravel-find-js-localizations'
);
$this->app->singleton(
'find-js-localizations.command.find-missing',
function ($app) {
return new FindMissing(
$app->make('File')->getFacadeRoot(),
$app['config']['laravel-find-js-localizations']
);
}
);
$this->commands('find-js-localizations.command.find-missing');
}
}