Skip to content

Commit

Permalink
Sync with template
Browse files Browse the repository at this point in the history
  • Loading branch information
vudaltsov committed Sep 4, 2024
1 parent d578711 commit e7a83b3
Show file tree
Hide file tree
Showing 9 changed files with 2,174 additions and 30 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
name: Check

on:
workflow_dispatch: ~
push:
branches: ['*.x']
branches: ['main', '*.*.x']
pull_request: ~

jobs:
Expand All @@ -22,6 +21,7 @@ jobs:
- run: composer validate
- run: composer normalize --dry-run
- run: composer check-require
- run: composer check-unused

lint:
runs-on: ubuntu-latest
Expand Down
8 changes: 0 additions & 8 deletions .php-cs-fixer.dist.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,6 @@

(new PhpCsFixerCodingStandard())->applyTo($config, [
'final_public_method_for_abstract_class' => false,
'ordered_class_elements' => ['order' => ['use_trait']],
'class_attributes_separation' => ['elements' => [
'trait_import' => 'only_if_meta',
'const' => 'only_if_meta',
'case' => 'only_if_meta',
'property' => 'one',
'method' => 'one',
]],
]);

return $config;
12 changes: 3 additions & 9 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -54,25 +54,19 @@
"extra": {
"bamarni-bin": {
"bin-links": false,
"forward-command": false,
"forward-command": true,
"target-directory": "tools"
}
},
"scripts": {
"post-install-cmd": "@install-tools",
"post-update-cmd": "@install-tools",
"bump-dev": [
"@composer bump --dev-only",
"@composer bump --dev-only --working-dir=tools/composer-require-checker",
"@composer bump --dev-only --working-dir=tools/psalm"
"@composer bin all bump --dev-only"
],
"check-require": "tools/composer-require-checker/vendor/bin/composer-require-checker",
"check-unused": "tools/composer-unused/vendor/bin/composer-unused",
"fixcs": "php-cs-fixer fix --diff",
"infection": "infection --show-mutations",
"install-tools": [
"@composer bin psalm install",
"@composer bin composer-require-checker install"
],
"pre-command-run": "mkdir -p var",
"psalm": "tools/psalm/vendor/bin/psalm --show-info --no-diff --no-cache",
"test": "phpunit"
Expand Down
2 changes: 1 addition & 1 deletion composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion psalm.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,5 @@
<function name="print"/>
<function name="sleep"/>
<function name="usleep"/>
<function name="var_dump"/>
</forbiddenFunctions>
</psalm>
10 changes: 10 additions & 0 deletions tools/composer-unused/composer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"require-dev": {
"icanhazstring/composer-unused": "^0.8.11"
},
"config": {
"platform": {
"php": "8.1"
}
}
}
Loading

0 comments on commit e7a83b3

Please sign in to comment.