Skip to content

Commit 3ca08ac

Browse files
authored
Add a github action on pull request to check lua formatting (#526)
GitHub Action used: https://github.com/marketplace/actions/stylua This runs `stylua --check` on a PR and it will show success or failure. The suggested stylua changes can be inspected when clicking on the details. The PR can still be merged even if the check fails.
1 parent 39ae082 commit 3ca08ac

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

.github/workflows/stylua.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# Check Lua Formatting
2+
name: Check Lua Formatting
3+
on: pull_request
4+
5+
jobs:
6+
stylua-check:
7+
name: Stylua Check
8+
runs-on: ubuntu-latest
9+
steps:
10+
- name: Checkout Code
11+
uses: actions/checkout@v2
12+
- name: Stylua Check
13+
uses: JohnnyMorganz/stylua-action@v3
14+
with:
15+
token: ${{ secrets.GITHUB_TOKEN }}
16+
version: latest
17+
args: --check .
18+

0 commit comments

Comments
 (0)