]> git.mxchange.org Git - friendica.git/commitdiff
Add PHP CS Fixer tool
authorHypolite Petovan <ben.lort@gmail.com>
Mon, 3 Oct 2016 12:50:31 +0000 (08:50 -0400)
committerHypolite Petovan <ben.lort@gmail.com>
Mon, 3 Oct 2016 12:50:31 +0000 (08:50 -0400)
- Add executable in `util`
- Add config file for a project-wide run of the fixer

.php_cs [new file with mode: 0644]
php-cs-fixer.phar [new file with mode: 0644]

diff --git a/.php_cs b/.php_cs
new file mode 100644 (file)
index 0000000..d47c4e0
--- /dev/null
+++ b/.php_cs
@@ -0,0 +1,16 @@
+<?php
+
+$finder = Symfony\CS\Finder\DefaultFinder::create()
+    ->exclude('doc')
+    ->exclude('images')
+    ->exclude('js')
+    ->exclude('library')
+    ->exclude('mods')
+    ->exclude('spec')
+    ->in(__DIR__)
+;
+
+return Symfony\CS\Config\Config::create()
+    ->level(Symfony\CS\FixerInterface::PSR2_LEVEL)
+    ->finder($finder)
+;
diff --git a/php-cs-fixer.phar b/php-cs-fixer.phar
new file mode 100644 (file)
index 0000000..71c5cfb
Binary files /dev/null and b/php-cs-fixer.phar differ