lua-users home
lua-l archive

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


G'day,

[Brief ActiveState diversion, that partially provoked this message:  I
enjoyed their Tcl/Tk packaged version in the late 90's, and left behind
me some satisfied customers... so this message is partially looking at
the Lua ecosystem with a slight ActiveState flavour...]

Having seen that a Lisp-ish or Scheme-ish high-level language, plus
straight C at the lower levels, seems to be the nature of more than one
project that's proven successful, I'm trying to centre my programming
universe around C + Lua.

LuaRocks is a non-trivial part of that ecosystem.  So, two
questions, loosely related on LuaRocks (the first is probably more
important than the second):

1. Given that I have some set of LuaRocks installed, is there an
   automated way of checking whether the main repository has a newer
   version?  I haven't seen an easy way to do this from the
   intrinsic help contained within the "luarocks" command; and

2. For some reason, I've tended to use the "strictness" lua rock
   instead of the "strict.lua" included with the distribution.  Am I
   introducing extra dependencies+pain for little gain by doing this?
   (I vaguely recall that there was some advantage to using
   "strictness" over "strict.lua", but I can't recall exact reasons...)

(Extra information that may be relevant:  I've held myself to version
5.1, minus deprecated features such as "module", but using various
LuaRocks occasionally (e.g. features such as bit32).  Does anything I've
said in this paragraph really affect the "strictness" versus
"strict.lua" pros and cons?)

- - - -

Easily, my heaviest use of LuaRocks is luaposix.  This is because I
want to execute external program(s) in a subprocess, but maintain a
vice-like grip over the parameter list. so that I don't have to worry
about parameter substitution, escapes, quoting, "Little Bobby Tables"
and the like.  Where I know the command supports it (usually because
it uses getopt()), I usually also prefix the filename list with "--".

The downside is that handy shell features, such as filename globbing,
are out of reach, and I have to use other parts of luaposix to do
this manually.

- - - -

--[[
Yet again, David A Wheeler has interesting and well-researched writing
on avoiding magic-shell-character hazards in programming, especially in
a POSIX environment.  He has an essay with a lot of examples where
attempted workarounds fail, along with a lot of information on how to
adopt good practices to avoid problems.  The essay also notes a couple
of cases where the Windows command shell can also bee vulnerable to
special characters in filenames.

        <a href="http://www.dwheeler.com/essays/filenames-in-shell.html";>
        Filenames and Pathnames in Shell: How to do it Correctly
        </a>

--]]

- - - -

Thanks in advance for any help on the LuaRocks versioning and/or
strictness front.

cheers,

s-b etc.