Skip to content

Commit 78ece0b

Browse files
push stylua.yml
1 parent be0fd4f commit 78ece0b

File tree

1 file changed

+18
-1
lines changed

1 file changed

+18
-1
lines changed

.github/workflows/stylua.yml

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
11
name: Formatting
22

3-
on: [push, pull_request_target]
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
paths-ignore:
7+
- ".github/**"
8+
- "**.md"
9+
- "**.norg"
410

511
jobs:
612
format-with-stylua:
@@ -29,3 +35,14 @@ jobs:
2935

3036
- name: Run formatting
3137
run: stylua -v --verify .
38+
39+
- uses: stefanzweifel/git-auto-commit-action@v4
40+
with:
41+
commit_message: "chore: autoformat with stylua"
42+
branch: ${{ github.ref }}
43+
44+
- name: Push changes
45+
uses: ad-m/github-push-action@master
46+
with:
47+
github_token: ${{ secrets.GITHUB_TOKEN }}
48+
branch: ${{ github.ref }}

0 commit comments

Comments
 (0)