On 18 May 2014 00:40, Peter Billam <p...@pjb.com.au> wrote: > Choonster wrote: >> I just installed the rock on an Ubuntu VM with a fresh copy of >> LuaRocks and the Lua file was installed as "Readline.lua" rather >> than "readline.lua", which caused `require("readline")` to fail. >> Renaming the file to "readline.lua" allowed it to work. >> I believe it's installed this way because of the >> `Readline = "readline.lua"` line in the Rockspec. >> If you have a case-insensitive file system (which I think OS X >> uses by default), the case of the file probably doesn't matter >> to `require`. > > I'm on debian stable and not using a case-insensitive file system. > > I'm using /usr/local/bin/luarocks 2.1.0 > ~> find /usr/ -name '*eadline.lua' -print > /usr/local/share/lua/5.2/readline.lua > > Has capitalisation-relevant behaviour changed since 2.1.0 ?
No, LuaRocks has always been capitalization sensitive for modules. > modules = { > ["Terminfo"] = "Terminfo.lua" > }, This should install Terminfo.lua with a capital T > there's also the line: > package = "Terminfo" This one is for informative purposes only. The rockspec file must be all-lowercase, and package:lower() must match the rockspec name, but package can be capitalized as one likes best, in order to show up in the index page (e.g. LuaSocket, LuaSQL...) > and yet it installed as /usr/local/share/lua/5.2/terminfo.lua and: > local T = require 'terminfo' > works for me... > > Could I just make every occurrence lowercase, > or are there some letters that need to be uppercase ? > > Only really in the module: > local C = require 'CommandLineUI' If `modules = { ["Terminfo"] = "Terminfo.lua" }` installs terminfo.lua in lowercase, then there's probably a bug somewhere. LuaRocks should respect the casing of the module as specified by the author. (Having different modules differing only on casing is probably bad for portability, though.) -- Hisham ------------------------------------------------------------------------------ "Accelerate Dev Cycles with Automated Cross-Browser Testing - For FREE Instantly run your Selenium tests across 300+ browser/OS combos. Get unparalleled scalability from the best Selenium testing platform available Simple to use. Nothing to install. Get started now for free." http://p.sf.net/sfu/SauceLabs _______________________________________________ Luarocks-developers mailing list Luarocks-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/luarocks-developers