2021-10-05 15:13:10 +08:00
|
|
|
name: lint
|
|
|
|
|
|
|
|
on:
|
|
|
|
pull_request:
|
|
|
|
branches:
|
|
|
|
- master
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
lint:
|
2022-03-20 10:22:32 +08:00
|
|
|
runs-on: ubuntu-latest
|
2021-10-05 15:13:10 +08:00
|
|
|
steps:
|
2022-03-20 10:22:32 +08:00
|
|
|
- name: Checkout sources
|
2022-07-24 16:14:35 +08:00
|
|
|
uses: actions/checkout@v3
|
2022-03-20 10:22:32 +08:00
|
|
|
|
|
|
|
- name: Run luacheck
|
2022-07-24 16:14:35 +08:00
|
|
|
uses: lunarmodules/luacheck@v0
|
|
|
|
with:
|
|
|
|
args: lua/* test/*
|
2022-03-20 10:22:32 +08:00
|
|
|
|
|
|
|
- name: Run selene
|
2022-07-24 16:14:35 +08:00
|
|
|
uses: NTBBloodbath/selene-action@v1.0.0
|
|
|
|
with:
|
|
|
|
token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
args: --display-style=quiet .
|
2022-03-20 10:22:32 +08:00
|
|
|
|
2021-10-05 15:13:10 +08:00
|
|
|
style-lint:
|
2022-03-20 10:22:32 +08:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: Checkout sources
|
2022-07-24 16:14:35 +08:00
|
|
|
uses: actions/checkout@v3
|
2022-03-20 10:22:32 +08:00
|
|
|
|
|
|
|
- name: Lint with stylua
|
|
|
|
uses: JohnnyMorganz/stylua-action@1.0.0
|
|
|
|
with:
|
|
|
|
token: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
# CLI arguments
|
|
|
|
args: --check .
|