diff --git a/readme.md b/readme.md index 5d5a712..d50e73c 100644 --- a/readme.md +++ b/readme.md @@ -4,7 +4,7 @@ Add the helper file to your laravel folder (not in a public folder). The file isn't used by Laravel, but it has to be indexed by your IDE. -* Netbeans 7 and PHPStorm 6 version: https://gist.github.com/barryvdh/5227822 +* Netbeans and PHPStorm version: https://gist.github.com/barryvdh/5227822 * SublimeText CodeIntel version: https://gist.github.com/barryvdh/5227814 ### Automatic phpDoc generation for Laravel Facades @@ -25,7 +25,7 @@ If you use SublimeText CodeIntel, the format is a bit different. So add --sublim php artisan ide-helper:generate -S -You can also publish the config-file to add extra facades (ie. for bundles). +You can also publish the config-file to add extra facades (ie. for bundles) or set defaults for --helpers or --sublime. php artisan config:publish barryvdh/laravel-ide-helper diff --git a/src/Barryvdh/LaravelIdeHelper/GeneratorCommand.php b/src/Barryvdh/LaravelIdeHelper/GeneratorCommand.php index a24f62b..7a71b0f 100644 --- a/src/Barryvdh/LaravelIdeHelper/GeneratorCommand.php +++ b/src/Barryvdh/LaravelIdeHelper/GeneratorCommand.php @@ -41,7 +41,9 @@ class GeneratorCommand extends Command { $helpers = array(); } - $content = $this->generateDocs($aliases, $helpers, $this->option('sublime')); + $sublime = $this->option('sublime') || \Config::get('laravel-ide-helper::sublime'); + + $content = $this->generateDocs($aliases, $helpers, $sublime); $written = \File::put($filename, $content); diff --git a/src/config/config.php b/src/config/config.php index 1428cf2..a3ea34b 100644 --- a/src/config/config.php +++ b/src/config/config.php @@ -13,6 +13,18 @@ return array( 'filename' => '_IDE_helper.php', + /* + |-------------------------------------------------------------------------- + | Sublime version + |-------------------------------------------------------------------------- + | + | Use a different code format, better for SublimeText (instead of Netbeans/phpStorm) + | Can also be used with the --sublime (-S) option. + | + */ + + 'sublime' => false, + /* |-------------------------------------------------------------------------- | Helper files to include