Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit cc37c49

Browse files
committed
Synchronize coding standard workflow with upstream
Now that there no longer are cs issues, we can thank diff-sniffer and kiss it goodbye!
1 parent 95824ef commit cc37c49

1 file changed

Lines changed: 11 additions & 15 deletions

File tree

.github/workflows/coding-standard.yml

Lines changed: 11 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,16 @@ name: "Coding Standards"
22

33
on:
44
pull_request:
5+
branches:
6+
- "*.x"
7+
push:
8+
branches:
9+
- "*.x"
510

611
jobs:
712
coding-standards:
813
name: "Coding Standards"
9-
runs-on: "ubuntu-latest"
14+
runs-on: "ubuntu-20.04"
1015

1116
strategy:
1217
matrix:
@@ -16,8 +21,6 @@ jobs:
1621
steps:
1722
- name: "Checkout"
1823
uses: "actions/checkout@v2"
19-
with:
20-
fetch-depth: 10
2124

2225
- name: "Install PHP"
2326
uses: "shivammathur/setup-php@v2"
@@ -28,16 +31,9 @@ jobs:
2831

2932
- name: "Install dependencies with Composer"
3033
uses: "ramsey/composer-install@v1"
34+
with:
35+
dependency-versions: "highest"
3136

32-
- name: "Install diff-sniffer"
33-
run: "wget https://github.com/diff-sniffer/diff-sniffer/releases/download/0.5.1/diff-sniffer.phar"
34-
35-
- name: "Fetch head branch"
36-
run: "git remote set-branches --add origin $GITHUB_BASE_REF && git fetch origin $GITHUB_BASE_REF"
37-
38-
- name: "Run diff-sniffer"
39-
run: "php diff-sniffer.phar origin/$GITHUB_BASE_REF...$GITHUB_SHA --report=checkstyle | cs2pr"
40-
41-
- name: "Run phpcbf"
42-
run: "vendor/bin/phpcbf"
43-
37+
# https://github.com/doctrine/.github/issues/3
38+
- name: "Run PHP_CodeSniffer"
39+
run: "vendor/bin/phpcs -q --no-colors --report=checkstyle | cs2pr"

0 commit comments

Comments
 (0)