Skip to content

Commit 12b8a12

Browse files
committed
feat: add auto fmt on ci
1 parent 6003741 commit 12b8a12

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

.github/workflows/lint.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,3 +22,13 @@ jobs:
2222
run: yarn install
2323
- name: Lint
2424
run: yarn nx format:check --all
25+
continue-on-error: true # Continue even if the check fails
26+
- name: Auto-format and commit changes if needed
27+
if: failure()
28+
run: |
29+
yarn nx format:write --all
30+
git config --global user.name "GitHub Actions"
31+
git config --global user.email "[email protected]"
32+
git add .
33+
git commit -m "fmt"
34+
git push

0 commit comments

Comments
 (0)