aboutsummaryrefslogtreecommitdiffstats
path: root/.luacheckrc
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2017-03-06 15:31:21 +0100
committerKim Alvefur <zash@zash.se>2017-03-06 15:31:21 +0100
commit12b74e9dde7fbabe26e3bcca7d0249621344476a (patch)
tree12c170f5c451cd6de06f1b842d220909e39f46e9 /.luacheckrc
parent0e71fac1d18b0de0e9203cb6b71c971d55c8c70c (diff)
parenta889b0287767bd9e7ab5f213607f453acac448f9 (diff)
downloadprosody-12b74e9dde7fbabe26e3bcca7d0249621344476a.tar.gz
prosody-12b74e9dde7fbabe26e3bcca7d0249621344476a.zip
Merge 0.10->trunk
Diffstat (limited to '.luacheckrc')
-rw-r--r--.luacheckrc76
1 files changed, 74 insertions, 2 deletions
diff --git a/.luacheckrc b/.luacheckrc
index 0040cfbb..d931da66 100644
--- a/.luacheckrc
+++ b/.luacheckrc
@@ -5,7 +5,7 @@ allow_defined_top = true
module = true
unused_secondaries = false
codes = true
-ignore = { "411/err", "421/err", "411/ok", "421/ok", "211/_ENV" }
+ignore = { "411/err", "421/err", "411/ok", "421/ok", "211/_ENV", "431/log" }
max_line_length = 150
@@ -14,7 +14,79 @@ files["core/"] = {
globals = { "prosody.hosts.?", "hosts.?" };
}
files["plugins/"] = {
- globals = { "module" };
+ read_globals = {
+ -- Module instance
+ "module.name",
+ "module.host",
+ "module._log",
+ "module.log",
+ "module.event_handlers",
+ "module.reloading",
+ "module.saved_state",
+ "module.environment",
+ "module.global",
+ "module.path",
+
+ -- Module API
+ "module.add_extension",
+ "module.add_feature",
+ "module.add_identity",
+ "module.add_item",
+ "module.add_timer",
+ "module.broadcast",
+ "module.context",
+ "module.depends",
+ "module.fire_event",
+ "module.get_directory",
+ "module.get_host",
+ "module.get_host_items",
+ "module.get_host_type",
+ "module.get_name",
+ "module.get_option",
+ "module.get_option_array",
+ "module.get_option_boolean",
+ "module.get_option_inherited_set",
+ "module.get_option_number",
+ "module.get_option_path",
+ "module.get_option_set",
+ "module.get_option_string",
+ "module.handle_items",
+ "module.has_feature",
+ "module.has_identity",
+ "module.hook",
+ "module.hook_global",
+ "module.hook_object_event",
+ "module.hook_tag",
+ "module.load_resource",
+ "module.measure",
+ "module.measure_event",
+ "module.measure_global_event",
+ "module.measure_object_event",
+ "module.open_store",
+ "module.provides",
+ "module.remove_item",
+ "module.require",
+ "module.send",
+ "module.set_global",
+ "module.shared",
+ "module.unhook",
+ "module.unhook_object_event",
+ "module.wrap_event",
+ "module.wrap_global",
+ "module.wrap_object_event",
+ };
+ globals = {
+ "_M",
+
+ -- Methods that can be set on module API
+ "module.unload",
+ "module.add_host",
+ "module.load",
+ "module.add_host",
+ "module.save",
+ "module.restore",
+ "module.command",
+ };
}
files["tests/"] = {
read_globals = {