add luacheck, add github action for luacheck, fix luacheck warnings, remove depreciated files
parent
052cbb98d0
commit
f49bc09de2
|
@ -0,0 +1,18 @@
|
||||||
|
|
||||||
|
name: luacheck
|
||||||
|
|
||||||
|
on: [push, pull_request]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v1
|
||||||
|
- name: apt
|
||||||
|
run: sudo apt-get install -y luarocks
|
||||||
|
- name: luacheck install
|
||||||
|
run: luarocks install --local luacheck
|
||||||
|
- name: luacheck run
|
||||||
|
run: $HOME/.luarocks/bin/luacheck ./
|
|
@ -0,0 +1,24 @@
|
||||||
|
unused_args = false
|
||||||
|
allow_defined_top = true
|
||||||
|
|
||||||
|
exclude_files = {".luacheckrc"}
|
||||||
|
|
||||||
|
globals = {
|
||||||
|
"minetest", "core",
|
||||||
|
|
||||||
|
--mod provided
|
||||||
|
}
|
||||||
|
|
||||||
|
read_globals = {
|
||||||
|
string = {fields = {"split"}},
|
||||||
|
table = {fields = {"copy", "getn"}},
|
||||||
|
|
||||||
|
--luac
|
||||||
|
"math", "table",
|
||||||
|
|
||||||
|
-- Builtin
|
||||||
|
"vector", "ItemStack", "dump", "DIR_DELIM", "VoxelArea", "Settings", "PcgRandom", "VoxelManip", "PseudoRandom",
|
||||||
|
|
||||||
|
--mod produced
|
||||||
|
"default",
|
||||||
|
}
|
|
@ -1,2 +0,0 @@
|
||||||
default
|
|
||||||
dye
|
|
|
@ -1 +0,0 @@
|
||||||
Adds faintly glowing coloured glass panes which can be used for stained glass windows or for gentle lighting.
|
|
8
init.lua
8
init.lua
|
@ -1,5 +1,5 @@
|
||||||
|
|
||||||
function register_pane(name, def)
|
local function register_pane(name, def)
|
||||||
for i = 1, 15 do
|
for i = 1, 15 do
|
||||||
minetest.register_alias("xpanes:" .. name .. "_" .. i, "xpanes:" .. name .. "_flat")
|
minetest.register_alias("xpanes:" .. name .. "_" .. i, "xpanes:" .. name .. "_flat")
|
||||||
end
|
end
|
||||||
|
@ -66,9 +66,9 @@ end
|
||||||
|
|
||||||
local panes_list = {
|
local panes_list = {
|
||||||
{"white", "White", "ffffff", }, {"blue", "Blue", "0000FF", },
|
{"white", "White", "ffffff", }, {"blue", "Blue", "0000FF", },
|
||||||
{"cyan", "Cyan", "00FFFF", }, {"green", "Green", "00FF00", },
|
{"cyan", "Cyan", "00FFFF", }, {"green", "Green", "00FF00", },
|
||||||
{"magenta", "Magenta", "FF00FF", }, {"orange", "Orange", "FF6103", },
|
{"magenta", "Magenta", "FF00FF", }, {"orange", "Orange", "FF6103", },
|
||||||
{"violet", "Purple", "800080", }, {"red", "Red", "FF0000", },
|
{"violet", "Purple", "800080", }, {"red", "Red", "FF0000", },
|
||||||
{"yellow", "Yellow", "FFFF00", },
|
{"yellow", "Yellow", "FFFF00", },
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue