-
-
Notifications
You must be signed in to change notification settings - Fork 3
/
.gitlab-ci.yml
42 lines (39 loc) · 1.17 KB
/
.gitlab-ci.yml
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
stages:
- test
test:
stage: test
image: ubuntu:latest
variables:
LUA_VERSION: "5.1.5"
LUAROCKS_VERSION: "2.4.2" # Adjust the version as per your requirements
script:
- apt-get update && apt-get install -y wget unzip make git gcc libreadline-dev libncurses-dev
- wget https://github.com/neovim/neovim/releases/download/stable/nvim-linux64.tar.gz
- tar xzvf nvim-linux64.tar.gz
- export PATH="$(pwd)/nvim-linux64/bin:$PATH"
# Install specific Lua version and Luarocks
- wget https://www.lua.org/ftp/lua-$LUA_VERSION.tar.gz
- tar zxf lua-$LUA_VERSION.tar.gz
- cd lua-$LUA_VERSION
- make linux test
- make install
- cd ..
- wget https://luarocks.org/releases/luarocks-$LUAROCKS_VERSION.tar.gz
- tar zxpf luarocks-$LUAROCKS_VERSION.tar.gz
- cd luarocks-$LUAROCKS_VERSION
- ./configure && make && make install
- cd ..
# Install Lua dependencies
- luarocks install luacheck
# Install other dependencies
- make -C ./test prepare
# Run linter
- luacheck lua/ test/spec/ --no-max-line-length
# Run tests
- make -C ./test test
only:
- main
# - dev
- alpha
except:
- tags