0bc896dc9fe38961f7b4279daaa5383536e28813
[GitHub/WoltLab/com.woltlab.wcf.conversation.git] / .github / workflows / codestyle.yml
1 name: Code Style
2
3 on:
4 push:
5 branches:
6 - "5.2"
7 - "5.3"
8 - master
9 pull_request:
10
11 jobs:
12 php:
13 name: PHP
14 runs-on: ubuntu-latest
15 steps:
16 - uses: actions/checkout@v2
17 - name: phpcs
18 uses: chekalsky/phpcs-action@e269c2f264f400adcda7c6b24c8550302350d495
19 - name: php-cs-fixer
20 uses: docker://oskarstark/php-cs-fixer-ga
21 with:
22 args: --dry-run --diff-format udiff
23 ts:
24 name: TS Prettier
25 runs-on: ubuntu-latest
26 steps:
27 - uses: actions/checkout@v2
28 - run: npm install
29 - name: Run prettier
30 run: |
31 shopt -s globstar
32 npx prettier -w ts/**/*.ts
33 - run: echo "::add-matcher::.github/diff.json"
34 - name: Show diff
35 run: |
36 git checkout -- package-lock.json
37 git diff --exit-code