APItools / middleware

APItools Middleware Repository
MIT License
61 stars 35 forks source link

add luacheck #11

Closed mikz closed 10 years ago

kikito commented 10 years ago

May I suggest doing luac -p middleware/**/*.lua instead of luacheck? luac comes by default when you install lua, while luacheck has dependencies (and makes Travis fail). Also, luac seems to be the standard way of checking for syntax errors (it's what my vim plugin uses, for example).

mikz commented 10 years ago

Ideally it should check not only for syntax errors, but using global vars we don't provide and similar.

kikito commented 10 years ago

I have tried adding our globals to luacheck but I could not deduce how to use the --global option. I have opened an issue on luacheck on this regard: https://github.com/mpeterv/luacheck/issues/4

mikz commented 10 years ago

I failed too :)

On 20. 8. 2014, at 19:32, Enrique García notifications@github.com wrote:

I have tried adding our globals to luacheck but I could not deduce how to use the --global option. I have opened an issue on luacheck on this regard: mpeterv/luacheck#4

— Reply to this email directly or view it on GitHub.

mpeterv commented 10 years ago

Hello! I explained how to use the --globals option(mpeterv/luacheck#4). luacheck is probably not very user friendly but it's hard for me as its creator to tell what exactly should be improved. Please tell me if there will be any other problems.

mpeterv commented 10 years ago

By the way, Travis build fails because of a bug in the old version of luarocks which is installed with apt-get.

mikz commented 10 years ago

@mpeterv thanks very much! will fix it