Skip to content

Commit f552e98

Browse files
committed
ci: update lint
1 parent 6e380ec commit f552e98

File tree

3 files changed

+55
-1
lines changed

3 files changed

+55
-1
lines changed

.github/workflows/lint.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,4 +26,4 @@ jobs:
2626
run: luarocks install luacheck
2727

2828
- name: Run luacheck
29-
run: luacheck *.lua lua/* tests/*
29+
run: luacheck *.lua lua/*

.luacheckrc

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
---@diagnostic disable
2+
-- vim: ft=lua tw=80
3+
4+
stds.nvim = {
5+
globals = {
6+
"lvim",
7+
"reload",
8+
vim = { fields = { "g" } },
9+
"TERMINAL",
10+
"USER",
11+
"C",
12+
"Config",
13+
"WORKSPACE_PATH",
14+
"JAVA_LS_EXECUTABLE",
15+
"MUtils",
16+
"USER_CONFIG_PATH",
17+
os = { fields = { "capture" } },
18+
},
19+
read_globals = {
20+
"jit",
21+
"os",
22+
"vim",
23+
"join_paths",
24+
"get_runtime_dir",
25+
"get_config_dir",
26+
"get_cache_dir",
27+
"get_lvim_base_dir",
28+
"require_clean",
29+
},
30+
}
31+
std = "lua51+nvim"
32+
33+
files["tests/*_spec.lua"].std = "lua51+nvim+busted"
34+
files["lua/lvim/impatient*"].ignore = { "121" }
35+
36+
-- Don't report unused self arguments of methods.
37+
self = false
38+
39+
-- Rerun tests only if their modification time changed.
40+
cache = true
41+
42+
ignore = {
43+
"631", -- max_line_length
44+
"212/_.*", -- unused argument, for vars with "_" prefix
45+
}

.luarc.json

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"$schema": "https://raw.githubusercontent.com/sumneko/vscode-lua/master/setting/schema.json",
3+
"Lua.diagnostics.disable": [
4+
"redundant-parameter",
5+
"param-type-mismatch",
6+
"missing-parameter"
7+
],
8+
"diagnostics.libraryFiles": "Disable"
9+
}

0 commit comments

Comments
 (0)