Skip to content

Commit

Permalink
ci lint: add image-customization lint step
Browse files Browse the repository at this point in the history
We can lint the image-customization luafile to check if it is at least
valid Lua code.

Signed-off-by: David Bauer <mail@david-bauer.net>
  • Loading branch information
blocktrron committed Dec 26, 2023
1 parent f46f51b commit 545686c
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 0 deletions.
13 changes: 13 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,19 @@ jobs:
- name: Validate Shell Scripts
run: shellcheck $SHELL_FILES

image-customization:
name: "Image-Customization"
runs-on: ubuntu-22.04
env:
LUA_FILES: >-
image-customization.lua
steps:
- uses: actions/checkout@v4
- name: Install Dependencies
run: sudo apt-get -y update && sudo apt-get -y install lua-check
- name: Lint Image-Customization
run: luacheck --config contrib/site-luacheckrc $LUA_FILES

json:
name: "JSON"
runs-on: ubuntu-22.04
Expand Down
12 changes: 12 additions & 0 deletions contrib/site-luacheckrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
std = {
read_globals = {
"features",
"packages",
"broken",
"disable",
"disable_factory",
"device",
"target",
"device_class",
}
}

0 comments on commit 545686c

Please sign in to comment.