Skip to content

Commit 1c32d7f

Browse files
committed
ci(config): Update config files
- Add new patterns to ignore additional file types in archives. - Include /workbench/, *.mp4, *.tape, *.zip, and /testbench.yaml. - Ensure test and documentation files are excluded from archives. Signed-off-by: guanguans <[email protected]>
1 parent 1817898 commit 1c32d7f

13 files changed

+314
-80
lines changed

.ai-commit.json

Lines changed: 0 additions & 9 deletions
This file was deleted.

.git-blame-ignore-revs

Lines changed: 0 additions & 1 deletion
This file was deleted.

.gitattributes

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
*.phar binary
3232
*.mp4 binary
3333

34-
# Remove files for archives generated using `git archive`
34+
# Remove files for archives generated using `git archive --format=zip --output=soar-php.zip master -v`
3535
# Ignore all test and documentation with "export-ignore".
3636
/.*/ export-ignore
3737
/baselines/ export-ignore
@@ -41,16 +41,23 @@
4141
/tests/ export-ignore
4242
/vendor-bin/ export-ignore
4343
/vendor/ export-ignore
44+
/workbench/ export-ignore
4445

46+
*.mp4 export-ignore
47+
*.tape export-ignore
48+
*.zip export-ignore
4549
/.* export-ignore
4650
/CHANGELOG-*.md export-ignore
4751
/CHANGELOG.md export-ignore
52+
/composer-bump export-ignore
4853
/composer-dependency-analyser.php export-ignore
49-
/composer-updater export-ignore
5054
/monorepo-builder.php export-ignore
55+
/peck.json export-ignore
5156
/phpbench.json export-ignore
5257
/phpstan.neon export-ignore
5358
/phpunit.xml.dist export-ignore
5459
/rector-*.php export-ignore
5560
/rector.php export-ignore
61+
/rule-doc-generator export-ignore
62+
/testbench.yaml export-ignore
5663
/tests.* export-ignore

.gitignore

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,14 @@
44
vendor/
55

66
.DS_Store
7+
.env
78
.php-cs-fixer.cache
89
.phpunit.result.cache
10+
/*.zip
11+
/laravel
12+
/tests.*
913
clover.xml
1014
composer.lock
11-
laravel
1215
phpunit.xml
1316
psalm.xml
1417
soar.log
15-
tests.*

.lintmdrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
"no-long-code": [
2929
1,
3030
{
31-
"length": 10000,
31+
"length": 1000,
3232
"exclude": [
3333
"dot"
3434
]

.php-cs-fixer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -309,6 +309,6 @@
309309
->ignoreVCS(true)
310310
->ignoreVCSIgnored(true)
311311
->append([
312-
__DIR__.'/composer-updater',
312+
__DIR__.'/composer-bump',
313313
])
314314
);
File renamed without changes.

composer-dependency-analyser.php

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,19 +22,18 @@
2222
false
2323
)
2424
->addPathsToExclude([
25-
__DIR__.'/src/Support/Rectors/',
2625
__DIR__.'/src/Support/ComposerScripts.php',
26+
__DIR__.'/src/Support/Rectors/',
2727
__DIR__.'/tests/',
2828
])
2929
->ignoreUnknownClasses([
30-
// SensitiveParameter::class,
31-
'SensitiveParameter',
30+
// '\SensitiveParameter',
3231
])
3332
/** @see \ShipMonk\ComposerDependencyAnalyser\Analyser::CORE_EXTENSIONS */
3433
->ignoreErrorsOnExtensions(
3534
[
36-
// 'ext-ctype',
37-
// 'ext-mbstring',
35+
'ext-ctype',
36+
'ext-mbstring',
3837
],
3938
[ErrorType::SHADOW_DEPENDENCY],
4039
)
@@ -43,6 +42,11 @@
4342
__DIR__.'/src/Support/helpers.php',
4443
[ErrorType::SHADOW_DEPENDENCY]
4544
)
45+
->ignoreErrorsOnPackageAndPath(
46+
'symfony/polyfill-php82',
47+
__DIR__.'/src/Concerns/HasSudoPassword.php',
48+
[ErrorType::DEV_DEPENDENCY_IN_PROD]
49+
)
4650
->ignoreErrorsOnPackageAndPath(
4751
'symfony/var-dumper',
4852
__DIR__.'/src/Concerns/WithDumpable.php',

composer.json

Lines changed: 256 additions & 54 deletions
Large diffs are not rendered by default.

monorepo-builder.php

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,12 @@
1818
use Guanguans\MonorepoBuilderWorker\UpdateChangelogViaGoReleaseWorker;
1919
use Guanguans\MonorepoBuilderWorker\UpdateChangelogViaNodeReleaseWorker;
2020
use Guanguans\MonorepoBuilderWorker\UpdateChangelogViaPhpReleaseWorker;
21+
use Symfony\Component\Console\Input\ArgvInput;
22+
use Symfony\Component\Console\Output\ConsoleOutput;
23+
use Symfony\Component\Console\Style\SymfonyStyle;
24+
use Symfony\Component\Process\ExecutableFinder;
25+
use Symfony\Component\Process\PhpExecutableFinder;
26+
use Symfony\Component\Process\Process;
2127
use Symplify\MonorepoBuilder\Config\MBConfig;
2228
use Symplify\MonorepoBuilder\Release\ReleaseWorker\AddTagToChangelogReleaseWorker;
2329
use Symplify\MonorepoBuilder\Release\ReleaseWorker\PushNextDevReleaseWorker;
@@ -30,7 +36,10 @@
3036

3137
return static function (MBConfig $mbConfig): void {
3238
require __DIR__.'/vendor/autoload.php';
39+
40+
require __DIR__.'/vendor-bin/php82/vendor/autoload.php';
3341
$mbConfig->defaultBranch('master');
42+
MBConfig::disableDefaultWorkers();
3443

3544
/**
3645
* release workers - in order to execute.
@@ -52,5 +61,20 @@
5261
// PushNextDevReleaseWorker::class,
5362
]);
5463

64+
if (!(new ArgvInput)->hasParameterOption('--dry-run')) {
65+
(new Process([
66+
(new PhpExecutableFinder)->find(),
67+
(new ExecutableFinder)->find($composer = 'composer', $composer),
68+
'run',
69+
'checks',
70+
]))
71+
->setEnv(['COMPOSER_MEMORY_LIMIT' => -1])
72+
->setTimeout(600)
73+
->mustRun(static function (string $type, string $buffer): void {
74+
$symfonyStyle ??= new SymfonyStyle(new ArgvInput, new ConsoleOutput);
75+
$symfonyStyle->write($buffer);
76+
});
77+
}
78+
5579
EnvironmentChecker::checks($workers);
5680
};

0 commit comments

Comments
 (0)