added caching
This commit is contained in:
parent
ea726ced89
commit
236dd62265
3 changed files with 33 additions and 11 deletions
|
@ -10,15 +10,16 @@ on:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
luacheck_errcheck:
|
luacheck_errcheck:
|
||||||
runs-on: docker
|
runs-on: ubuntu-latest
|
||||||
container: nickblah/lua:5.1-luarocks-alpine
|
|
||||||
steps:
|
steps:
|
||||||
|
- name: Install Lua and Luarocks
|
||||||
|
run: |
|
||||||
|
sudo apt-get update
|
||||||
|
sudo apt-get install -y lua5.1 luarocks
|
||||||
|
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Install C libraries
|
|
||||||
run: apk add build-base
|
|
||||||
|
|
||||||
- name: Install Luacheck
|
- name: Install Luacheck
|
||||||
run: luarocks install luacheck
|
run: luarocks install luacheck
|
||||||
|
|
||||||
|
|
|
@ -10,15 +10,35 @@ on:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
busted_unit_test:
|
busted_unit_test:
|
||||||
runs-on: docker
|
runs-on: ubuntu-latest
|
||||||
container: nickblah/lua:5.1-luarocks-alpine
|
|
||||||
steps:
|
steps:
|
||||||
|
# Cache all installation files for faster workflow
|
||||||
|
- name: Cache Lua
|
||||||
|
uses: actions/cache@v2
|
||||||
|
with:
|
||||||
|
path: |
|
||||||
|
/usr/lib/lua
|
||||||
|
/usr/local/lib/lua
|
||||||
|
/usr/local/share/lua
|
||||||
|
/usr/bin/lua
|
||||||
|
key: lua
|
||||||
|
|
||||||
|
- name: Cache Luarocks
|
||||||
|
uses: actions/cache@v2
|
||||||
|
with:
|
||||||
|
path: |
|
||||||
|
/usr/local/bin/luarocks
|
||||||
|
/usr/local/share/lua/5.1/luarocks
|
||||||
|
key: luarocks
|
||||||
|
|
||||||
|
- name: Install Lua and Luarocks
|
||||||
|
run: |
|
||||||
|
sudo apt-get update
|
||||||
|
sudo apt-get install -y lua5.1 luarocks
|
||||||
|
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Install C libraries
|
|
||||||
run: apk add build-base
|
|
||||||
|
|
||||||
- name: Install Busted
|
- name: Install Busted
|
||||||
run: luarocks install busted
|
run: luarocks install busted
|
||||||
|
|
||||||
|
|
|
@ -8,8 +8,9 @@
|
||||||
|
|
||||||
outputs = { self, nixpkgs, ...}:
|
outputs = { self, nixpkgs, ...}:
|
||||||
let
|
let
|
||||||
pkgs = import nixpkgs { inherit self; };
|
pkgs = nixpkgs.legacyPackages.x86_64-linux;
|
||||||
in {
|
in {
|
||||||
|
|
||||||
devShells.x86_64-linux.default = pkgs.mkShell {
|
devShells.x86_64-linux.default = pkgs.mkShell {
|
||||||
buildInputs = [
|
buildInputs = [
|
||||||
# Run CI/CD actions locally
|
# Run CI/CD actions locally
|
||||||
|
|
Loading…
Add table
Reference in a new issue