Skip to content

Commit

Permalink
Tag Laravel configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
leomarquine committed Aug 27, 2016
1 parent 74b054c commit bbcd98b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ Marquine\Etl\Providers\Laravel\EtlServiceProvider::class,

Publish the configuration file (`config/etl.php`) using the artisan command:
```
php artisan vendor:publish
php artisan vendor:publish --tag etl
```

## Example
Expand Down
10 changes: 6 additions & 4 deletions src/Providers/Laravel/EtlServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,13 @@ class EtlServiceProvider extends ServiceProvider
*/
public function boot()
{
$this->publishes([
__DIR__ . '/etl.php' => config_path('etl.php'),
]);

Etl::config(config('etl'));

if ($this->app->runningInConsole()) {
$this->publishes([
__DIR__ . '/etl.php' => config_path('etl.php'),
], 'etl');
}
}

/**
Expand Down

0 comments on commit bbcd98b

Please sign in to comment.