A very simple static analyzer for Lua
$ luarocks install globals-lua
This is a very simple Lua program that list reports global variable usage in Lua files, based on static analysis.
It uses 'luac', the Lua compiler, and parses the bytecode listing. No other dependencies. Works with both Lua 5.1 and 5.2.