diff options
| author | David T. Sadler <davidtsadler@googlemail.com> | 2026-09-05 15:55:37 +0100 |
|---|---|---|
| committer | David T. Sadler <davidtsadler@googlemail.com> | 2026-09-05 15:55:37 +0100 |
| commit | ee334cc9f37d605f1df436bad701106210487dde (patch) | |
| tree | 86acef61a6451b05de4728970261879e16eb3806 | |
| parent | cd72efc067e921de7e8f6ae09ac7ab8af750b106 (diff) | |
| parent | 5aef2f715b89e9e33680fe2d16f882c585f885d3 (diff) | |
Merge branch 'main' into howl
| -rw-r--r-- | .php-cs-fixer.php | 40 | ||||
| -rw-r--r-- | nvim/.config/nvim/lua/plugins/conform.lua | 3 |
2 files changed, 40 insertions, 3 deletions
diff --git a/.php-cs-fixer.php b/.php-cs-fixer.php new file mode 100644 index 0000000..c87e9f0 --- /dev/null +++ b/.php-cs-fixer.php @@ -0,0 +1,40 @@ +<?php + +declare(strict_types=1); + +use PhpCsFixer\Config; +use PhpCsFixer\Finder; + +$finder = Finder::create() + ->in([ + __DIR__ . '/public', + __DIR__ . '/src', + __DIR__ . '/tests', + ]) + ->name('*.php') + ->ignoreDotFiles(true) + ->ignoreVCS(true); + +return (new Config()) + ->setRules([ + '@PSR12' => true, + 'declare_strict_types' => true, + 'array_syntax' => ['syntax' => 'short'], + 'single_quote' => true, + 'ordered_imports' => ['sort_algorithm' => 'alpha'], + 'no_unused_imports' => true, + 'trailing_comma_in_multiline' => [ + 'elements' => ['arrays', 'arguments', 'parameters'], + ], + 'no_superfluous_phpdoc_tags' => [ + 'remove_inheritdoc' => true, + 'allow_mixed' => true, + ], + 'strict_param' => true, + 'method_argument_space' => [ + 'on_multiline' => 'ensure_fully_multiline', + ], + 'type_declaration_spaces' => true, + ]) + ->setRiskyAllowed(true) + ->setFinder($finder); diff --git a/nvim/.config/nvim/lua/plugins/conform.lua b/nvim/.config/nvim/lua/plugins/conform.lua index 2fb51cd..9404428 100644 --- a/nvim/.config/nvim/lua/plugins/conform.lua +++ b/nvim/.config/nvim/lua/plugins/conform.lua @@ -19,9 +19,6 @@ require("conform").setup({ asm = { "lsp" }, }, formatters = { - php_cs_fixer = { - command = "php-cs-fixer", - }, -- Biome is great because it doesn't require a node_modules folder to work. biome = { command = "biome", |
