Skip to content

Commit

Permalink
chore: create description for composer run command
Browse files Browse the repository at this point in the history
Some commands used in multiple projects can be abstracted on composer
run workflow.

The intent behind it is to reduce the cognitive load for developers.

The commands will be listed on `composer list` and can be executed
interactively with `composer run`.

Signed-off-by: 💻 Eher <[email protected]>
  • Loading branch information
EHER committed Jun 24, 2023
1 parent a2d5b53 commit 6766725
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 11 deletions.
9 changes: 3 additions & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,10 @@ jobs:
run: composer install --prefer-dist --classmap-authoritative
env:
COMPOSER_ROOT_VERSION: dev-master
- name: Run Phpunit
run: composer run phpunit

- name: Run PhpCs
if: matrix.php-versions == '8.2' && matrix.dependencies == 'normal'
run: composer run phpcs
- name: Run tests
run: composer run test

- name: Run Qodana
if: matrix.php-versions == '8.2' && matrix.dependencies == 'normal'
uses: JetBrains/[email protected]
uses: JetBrains/[email protected]
14 changes: 9 additions & 5 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,16 @@
}
},
"scripts": {
"phpcbf": "vendor/bin/phpcbf",
"phpcs": "vendor/bin/phpcs",
"phpunit": "vendor/bin/phpunit",
"fix": [
"phpcbf"
],
"test": [
"@phpcs",
"@phpunit"
"phpcs",
"phpunit"
]
},
"scripts-descriptions": {
"fix": "Fix some detected issues",
"test": "Run all tests"
}
}

0 comments on commit 6766725

Please sign in to comment.