Open mkusher opened 9 years ago
:+1:
Maybe this should be stored inside the .padawan folder?
@sekjun9878 this file is not autogenerated by padawan.php, you should create it manually. So for a new project your variant will need extra step - make dir .padawan :)
updated proposal: added php
prop
php
- version of php being used for running padawan. Could be 5 or 7. php 5.* will use nikic/PHP-Parser and php 7 will use built-in AST builder.
@mkusher php7 has a built-in ast node builder?
@sekjun9878 https://github.com/nikic/php-ast
@mkusher That however introduces an additional dependency on the php-ast extension (and therefore a need for a custom PHP build)? I guess it depends on the result of https://wiki.php.net/rfc/parser-extension-api but for the forseeable future it looks like just using PHP-Parser seems a better choice.
+1 would also be good to cascade back to a global configuration so I can f.e. ignore nested vendor files **/vendor
Given that this had not progress for so long, perhaps it makes more sense to add features incrementally? Something among the lines of searching for padawan.yaml
file and parsing the exclude dirs array?
I like the fact that there currently are no extra steps, the above will be an optional step for edge cases.
Proposal
Project file is a yaml(e.g.
.padawan.yml
) configuration for a project.Structure
here we have 3 sections:
plugins
- plugins you want to be enabled for this projectexclude
- files or folders you want to exclude from being indexedcache_dir
- folder for padawan.php cache for this projectphp
- version of php being used for running padawan. Could be 5 or 7. php5.* will use nikic/PHP-Parser and 7 will use built-in AST builder.Editors' plugins
Before editors were looking for composer.json file, now they will have to look for
.padawan.yml
first and only then look forcomposer.json
.