Skip to content

Commit 919b055

Browse files
Merge pull request #39989 from nextcloud/techdebt/noid/bump-coding-style
fix(CS): Ignore apps*/ directories which are gitignored
2 parents 4c2c53e + cc551ac commit 919b055

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

.php-cs-fixer.dist.php

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,17 @@
2121
->notPath('node_modules')
2222
->notPath('vendor')
2323
->in(__DIR__);
24+
25+
// Ignore additional app directories
26+
$rootDir = new \DirectoryIterator(__DIR__);
27+
foreach ($rootDir as $node) {
28+
if (str_starts_with($node->getFilename(), 'apps')) {
29+
$return = shell_exec('git check-ignore ' . escapeshellarg($node->getFilename() . '/'));
30+
31+
if ($return !== null) {
32+
$config->getFinder()->exclude($node->getFilename());
33+
}
34+
}
35+
}
36+
2437
return $config;

0 commit comments

Comments
 (0)