Add shared php-cs config
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
This commit is contained in:
parent
5a0856c4ab
commit
3eac89d448
|
@ -70,6 +70,7 @@ CVS/*
|
||||||
.svn/*
|
.svn/*
|
||||||
RCS/*
|
RCS/*
|
||||||
*.backup*
|
*.backup*
|
||||||
|
.php_cs.cache
|
||||||
|
|
||||||
# kdevelop
|
# kdevelop
|
||||||
.kdev
|
.kdev
|
||||||
|
|
|
@ -0,0 +1,19 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
declare(strict_types=1);
|
||||||
|
|
||||||
|
require_once './lib/composer/autoload.php';
|
||||||
|
|
||||||
|
use Nextcloud\CodingStandard\Config;
|
||||||
|
|
||||||
|
$config = new Config();
|
||||||
|
$config
|
||||||
|
->getFinder()
|
||||||
|
->ignoreVCSIgnored(true)
|
||||||
|
->exclude('config')
|
||||||
|
->exclude('data')
|
||||||
|
->notPath('3rdparty')
|
||||||
|
->notPath('composer')
|
||||||
|
->notPath('vendor')
|
||||||
|
->in(__DIR__);
|
||||||
|
return $config;
|
|
@ -35,6 +35,7 @@ $expectedFiles = [
|
||||||
'.idea',
|
'.idea',
|
||||||
'.jshintrc',
|
'.jshintrc',
|
||||||
'.mailmap',
|
'.mailmap',
|
||||||
|
'.php_cs.dist',
|
||||||
'.scrutinizer.yml',
|
'.scrutinizer.yml',
|
||||||
'.tag',
|
'.tag',
|
||||||
'.tx',
|
'.tx',
|
||||||
|
@ -51,6 +52,7 @@ $expectedFiles = [
|
||||||
'CHANGELOG.md',
|
'CHANGELOG.md',
|
||||||
'CODE_OF_CONDUCT.md',
|
'CODE_OF_CONDUCT.md',
|
||||||
'composer.json',
|
'composer.json',
|
||||||
|
'composer.lock',
|
||||||
'config',
|
'config',
|
||||||
'console.php',
|
'console.php',
|
||||||
'contribute',
|
'contribute',
|
||||||
|
|
|
@ -15,9 +15,12 @@
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
"jakub-onderka/php-parallel-lint": "^0.9.2",
|
"jakub-onderka/php-parallel-lint": "^0.9.2",
|
||||||
"jakub-onderka/php-console-highlighter": "^0.3.2"
|
"jakub-onderka/php-console-highlighter": "^0.3.2",
|
||||||
|
"nextcloud/coding-standard": "^0.1.0"
|
||||||
},
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"lint": "find . -name \\*.php -not -path './lib/composer/*' -exec php -l \"{}\" \\;"
|
"cs:fix": "php-cs-fixer fix",
|
||||||
}
|
"cs:check": "php-cs-fixer fix --dry-run",
|
||||||
|
"lint": "find . -name \\*.php -not -path './lib/composer/*' -exec php -l \"{}\" \\;"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue