Open gilles6 opened 3 years ago
maybe can't find the config file, try full path:
"php-cs-fixer.config": "/Users/me/.vscode/.php-cs-fixer.php",
Thanks!! Indeed, that was the problem.
Where should I put my .php-cs-fixer.php
file to use it globally with the default parameter ?
"php-cs-fixer.config": ".php-cs-fixer.php;.php-cs-fixer.dist.php;.php_cs;.php_cs.dist"
workspace root directory or .vscode directory
It's already in ~/.vscode
directory and I don't see any file from the config list which would override it in ~/.vscode/
or in my working directory (neither in root
nor in .vscode folder
).
Maybe VSCode is just not looking in ~/.vscode
by default. Is it looking somewhere else globally ?
I also tried to put php-cs-fixer.config
in these 2 folders, but it's not searching in these two folders either:
/Users/me/Library/Application Support/Code/
/Users/me/Library/Application Support/Code/User/
you can open develop tools and see args
I'm using VSCode with PHP CS Fixer
v3.1.0
, but rules don't seem to be applied.When I comment/uncomment
setIndent("\t")
, this setting is automatically applied and can be tested, but all rules insetRules()
are not applied. For instance, arrays like$myarray = array('foo', 'bar');
is not replaced by$myarray = ['foo', 'bar'];
while I have the rulearray_syntax' => ['syntax' => 'short']
.What's wrong with my configuration ?
/Users/me/.vscode/.php-cs-fixer.php
:VSCode settings regarding PHP CS Fixer:
I'm using VSCode extension vscode-php-cs-fixer.
This question was previously asked here.