Skip to content

Commit 4baa8e7

Browse files
committed
GitHub Actions: Lint on push to master
This should store the cache of dependencies that's usable from pull requests.
1 parent 2f27954 commit 4baa8e7

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

.github/workflows/lint.yml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
name: Lint
2-
on: [pull_request]
2+
on:
3+
push:
4+
branches:
5+
- master
6+
pull_request:
37

48
jobs:
59
lint:
@@ -23,9 +27,11 @@ jobs:
2327
restore-keys: |
2428
${{ runner.os }}-yarn-
2529
- run: yarn install --frozen-lockfile
26-
- run: yarn format
30+
- if: ${{ github.event_name == 'pull_request' }}
31+
run: yarn format
2732
- run: yarn lint:text
2833
- run: yarn lint:format
29-
- uses: stefanzweifel/git-auto-commit-action@v4
34+
- if: ${{ github.event_name == 'pull_request' }}
35+
uses: stefanzweifel/git-auto-commit-action@v4
3036
with:
3137
commit_message: Autoformat with Prettier

0 commit comments

Comments
 (0)