aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/luarocks/lint.lua14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/luarocks/lint.lua b/src/luarocks/lint.lua
index 62ced64d..e3bf34b5 100644
--- a/src/luarocks/lint.lua
+++ b/src/luarocks/lint.lua
@@ -37,5 +37,17 @@ function run(...)
37 return nil, "Failed loading rockspec: "..err 37 return nil, "Failed loading rockspec: "..err
38 end 38 end
39 39
40 return true 40 local ok = true
41
42 -- This should have been done in the type checker,
43 -- but it would break compatibility of other commands.
44 -- Making 'lint' alone be stricter shouldn't be a problem,
45 -- because extra-strict checks is what lint-type commands
46 -- are all about.
47 if not rs.description.license then
48 util.printerr("Rockspec has no license field.")
49 ok = false
50 end
51
52 return ok, ok or filename.." failed consistency checks."
41end 53end