-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #23 from alexplusde/master
wording
- Loading branch information
Showing
17 changed files
with
132 additions
and
73 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
name: PHP-CS-Fixer | ||
|
||
on: | ||
push: | ||
branches: [ master, main ] | ||
pull_request: | ||
branches: [ master, main ] | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
code-style: | ||
|
||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write # for Git to git apply | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Setup PHP | ||
uses: shivammathur/setup-php@v2 | ||
with: | ||
php-version: '8.1' | ||
extensions: gd, intl, pdo_mysql | ||
coverage: none # disable xdebug, pcov | ||
|
||
# install dependencies from composer.json | ||
- name: Install test dependencies | ||
env: | ||
COMPOSER: composer.json | ||
run: composer install --prefer-dist --no-progress | ||
|
||
# run php-cs-fixer, fix code styles | ||
- name: Run PHP CS Fixer | ||
run: composer cs-fix | ||
|
||
# commit and push fixed files | ||
- uses: stefanzweifel/git-auto-commit-action@v4 | ||
with: | ||
commit_message: Apply php-cs-fixer changes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
/composer.lock | ||
/.php-cs-fixer.cache | ||
/vendor |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
$finder = (new PhpCsFixer\Finder()) | ||
->in(__DIR__) | ||
; | ||
|
||
return (new Redaxo\PhpCsFixerConfig\Config()) | ||
->setFinder($finder) | ||
; |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"require-dev": { | ||
"redaxo/php-cs-fixer-config": "^2.0", | ||
"friendsofphp/php-cs-fixer": "^3.14" | ||
}, | ||
"scripts": { | ||
"cs-dry": "php-cs-fixer fix -v --ansi --dry-run --config=.php-cs-fixer.dist.php", | ||
"cs-fix": "php-cs-fixer fix -v --ansi --config=.php-cs-fixer.dist.php" | ||
} | ||
} |
Oops, something went wrong.