lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On Sat, Dec 3, 2011 at 3:49 PM, Rob Kendrick <rjek@rjek.com> wrote:
> On Fri, Dec 02, 2011 at 04:23:57PM -0200, Hisham wrote:
>> As a convenience, one can also run " eval `luarocks path` " from the
>> shell and have LUA_PATH and LUA_CPATH adjusted automatically if
>> desired.
>
> Assuming your shell is bash-like :) It probably won't work on Bourne
> shell, or others.

Sure, it's a convenience only. It outputs bash-like syntax by default
on Unix, and CMD syntax on Windows. We could output other syntaxes on
Unix systems (perhaps based on os.getenv("SHELL")?) but no one
requested this feature yet. In any case, it is already configurable so
users of other shells can adapt the output to their needs. For
csh-like shells, one can add this to their luarocks/config.lua:

export_lua_path=[[setenv LUA_PATH "%s"]]
export_lua_cpath=[[setenv LUA_CPATH "%s"]]

and LuaRocks will use that.

-- Hisham
http://hisham.hm/ - http://luarocks.org/