-
Notifications
You must be signed in to change notification settings - Fork 36
56 lines (55 loc) · 1.31 KB
/
lua.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
name: Lua
on:
pull_request:
branches:
- main
- develop
jobs:
lua_lint:
name: Lint Lua 💅
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Luacheck linter
uses: lunarmodules/luacheck@v1
with:
args: --globals vim --no-max-line-length -- .
lua_format:
name: Formatting Lua 💅
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Action
uses: JohnnyMorganz/stylua-action@v3
with:
token: ${{ secrets.GITHUB_TOKEN }}
version: latest
args: --check .
lua_test:
name: Run tests 🧪
strategy:
matrix:
nvim_version: [stable, nightly]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install neovim
uses: rhysd/action-setup-vim@v1
id: vim
with:
neovim: true
version: ${{ matrix.nvim_version }}
- name: Install luajit
uses: leafo/gh-actions-lua@v10
with:
luaVersion: "luajit-openresty"
- name: Install luarocks
uses: leafo/gh-actions-luarocks@v4
- name: Run tests
shell: bash
run: |
chmod +x lua-test.sh
./lua-test.sh