Discussion:
[ANN] LuaRocks 3.0.4
Hisham
2018-10-30 23:56:45 UTC
Permalink
Hello list,

This is a quick announcement that version 3.0.4 of LuaRocks, the Lua
package manager, has been tagged and uploaded to the usual locations.
You can find all links at https://luarocks.org — source packages for
all supported platforms and binaries for Windows and Linux x86-64 are
available.

LuaRocks 3.0.4 is a minor maintenance release. What's new:

* Fork-free platform detection at startup
* Improved detection of the default rockspec in commands such as `luarocks test`
* Various minor bugfixes

Cheers!

-- Hisham
Dirk Laurie
2018-10-31 06:21:10 UTC
Permalink
Post by Hisham
This is a quick announcement that version 3.0.4 of LuaRocks, the Lua
package manager, has been tagged and uploaded to the usual locations.
You can find all links at https://luarocks.org — source packages for
all supported platforms and binaries for Windows and Linux x86-64 are
available.
This is not criticism, it's just a comment from a Lua user, one that
has never lamented Lua's lack of a Python-like ecosystem.

What I miss most about version 3 is a seamless transition from version
2.2. I understand that 'luarocks install luarocks' cannot work,
building from source has so far also eluded me, but a binary for Linux
x86-64 might be painless, I hoped.

I unzipped it into a directory not in $PATH, and tried

$ /usr/local/src/PACKAGES/luarocks-3.0.4-linux-x86_64/luarocks list

Rocks installed for Lua 5.3
---------------------------
$

I.e. it does not find my 33 existing rocks.

There is a subtle difference (extra whitespace) in where they say the
configution file is.

Luarocks 2.2.1-2 says
System: /usr/local/etc/luarocks/config-5.3.lua (ok)

Luarocks 3.0.4 says:
System : /usr/local/etc/luarocks/config-5.3.lua (ok)

BTW the "After installation, a default config file called config.lua
will be installed at the directory defined by --sysconfdir." seems not
to apply to luarocks 3.0.4

$ /usr/local/src/PACKAGES/luarocks-3.0.4-linux-x86_64/luarocks --sysconfdir

Error: Invalid argument: unknown flag --sysconfdir. See --help.
Sean Conner
2018-10-31 07:01:01 UTC
Permalink
Post by Dirk Laurie
Post by Hisham
This is a quick announcement that version 3.0.4 of LuaRocks, the Lua
package manager, has been tagged and uploaded to the usual locations.
You can find all links at https://luarocks.org — source packages for
all supported platforms and binaries for Windows and Linux x86-64 are
available.
This is not criticism, it's just a comment from a Lua user, one that
has never lamented Lua's lack of a Python-like ecosystem.
What I miss most about version 3 is a seamless transition from version
2.2. I understand that 'luarocks install luarocks' cannot work,
building from source has so far also eluded me, but a binary for Linux
x86-64 might be painless, I hoped.
I had the same issue last month; Hisham and I went back and forth a few
times on the LuaRocks Developers mailing list. Here's the thread:

https://sourceforge.net/p/luarocks/mailman/message/36416169/

-spc (It was not a painless upgrade for me either ... )
Dirk Laurie
2018-10-31 07:18:12 UTC
Permalink
Post by Sean Conner
Post by Dirk Laurie
Post by Hisham
This is a quick announcement that version 3.0.4 of LuaRocks, the Lua
package manager, has been tagged and uploaded to the usual locations.
You can find all links at https://luarocks.org — source packages for
all supported platforms and binaries for Windows and Linux x86-64 are
available.
This is not criticism, it's just a comment from a Lua user, one that
has never lamented Lua's lack of a Python-like ecosystem.
What I miss most about version 3 is a seamless transition from version
2.2. I understand that 'luarocks install luarocks' cannot work,
building from source has so far also eluded me, but a binary for Linux
x86-64 might be painless, I hoped.
I had the same issue last month; Hisham and I went back and forth a few
https://sourceforge.net/p/luarocks/mailman/message/36416169/
-spc (It was not a painless upgrade for me either ... )
Well, I'm going with the "if it ain't broke don't fix it" approach. It
is indeed ironic that the very package that is supposed to make Lua
packages easy to install and maintain, itself isn't.
Hisham
2018-10-31 14:03:15 UTC
Permalink
Post by Dirk Laurie
Well, I'm going with the "if it ain't broke don't fix it" approach. It
is indeed ironic that the very package that is supposed to make Lua
packages easy to install and maintain, itself isn't.
It has to jump through all the hoops so that the other Lua packages
don't have to, so arguably it performs a harder task. :)

-- Hisham
Hisham
2018-10-31 14:00:14 UTC
Permalink
Post by Dirk Laurie
Post by Hisham
This is a quick announcement that version 3.0.4 of LuaRocks, the Lua
package manager, has been tagged and uploaded to the usual locations.
You can find all links at https://luarocks.org — source packages for
all supported platforms and binaries for Windows and Linux x86-64 are
available.
This is not criticism, it's just a comment from a Lua user, one that
has never lamented Lua's lack of a Python-like ecosystem.
What I miss most about version 3 is a seamless transition from version
2.2. I understand that 'luarocks install luarocks' cannot work,
building from source has so far also eluded me, but a binary for Linux
x86-64 might be painless, I hoped.
I unzipped it into a directory not in $PATH, and tried
$ /usr/local/src/PACKAGES/luarocks-3.0.4-linux-x86_64/luarocks list
Rocks installed for Lua 5.3
---------------------------
$
Looking at the bright side, I'm happy that the binary did run in your
system without any library clashes. :)
Post by Dirk Laurie
I.e. it does not find my 33 existing rocks.
Where are they installed? LuaRocks 3 dropped default support for
unversioned rocks trees (which caused problems for users with multiple
Lua versions), so if the path looks like /usr/lib/luarocks/rocks, it
needs to be converted to /usr/lib/luarocks/rocks-5.x (for the proper
Lua version).

Auto-converting is risky because users may have customizations in
their config files. But I think adding a warning message when an
unversion lib/luarocks/rocks dir is found would be a big improvement.

If your rocks tree lives at /usr/local/lib/luarocks/rocks or
$HOME/.luarocks/rocks, I believe simply renaming the "rocks" directory
to "rocks-5.3" should make LuaRocks 3 pick it up. Could you give that
a try? If it doesn't work, reverting will be safe and nothing will
break in your LR2 install.
Post by Dirk Laurie
There is a subtle difference (extra whitespace) in where they say the
configution file is.
This is true, but this is textual output meant for users to read, not
scripts. Scripts should use `luarocks config --system-config` to get
that information, and `luarocks config` to inspect the current active
LuaRocks configuration.
Post by Dirk Laurie
Luarocks 2.2.1-2 says
System: /usr/local/etc/luarocks/config-5.3.lua (ok)
System : /usr/local/etc/luarocks/config-5.3.lua (ok)
Out of curiosity, what are the contents of
/usr/local/etc/luarocks/config-5.3.lua ?
Post by Dirk Laurie
BTW the "After installation, a default config file called config.lua
will be installed at the directory defined by --sysconfdir." seems not
to apply to luarocks 3.0.4
Is this from https://github.com/luarocks/luarocks/wiki/Installation-instructions-for-Unix
? The --sysconfdir flag there refers to the configure script which is
being discussed in that section. The instructions in that page do not
apply to the prebuilt binary.
Post by Dirk Laurie
$ /usr/local/src/PACKAGES/luarocks-3.0.4-linux-x86_64/luarocks --sysconfdir
Error: Invalid argument: unknown flag --sysconfdir. See --help.
I would love to add "setter" options to `luarocks config` so that
users can customize their configuration using commands, like `git
config` does. I am however, wary of rewriting user configuration files
which may contain arbitrary Lua code.

Thank you for the constructive feedback!

-- Hisham
Dirk Laurie
2018-10-31 19:29:45 UTC
Permalink
Post by Hisham
Post by Dirk Laurie
Post by Hisham
This is a quick announcement that version 3.0.4 of LuaRocks, the Lua
package manager, has been tagged and uploaded to the usual locations.
You can find all links at https://luarocks.org — source packages for
all supported platforms and binaries for Windows and Linux x86-64 are
available.
This is not criticism, it's just a comment from a Lua user, one that
has never lamented Lua's lack of a Python-like ecosystem.
What I miss most about version 3 is a seamless transition from version
2.2. I understand that 'luarocks install luarocks' cannot work,
building from source has so far also eluded me, but a binary for Linux
x86-64 might be painless, I hoped.
I unzipped it into a directory not in $PATH, and tried
$ /usr/local/src/PACKAGES/luarocks-3.0.4-linux-x86_64/luarocks list
Rocks installed for Lua 5.3
---------------------------
$
Looking at the bright side, I'm happy that the binary did run in your
system without any library clashes. :)
Post by Dirk Laurie
I.e. it does not find my 33 existing rocks.
Where are they installed?
In /usr/local/lib/luarocks/rocks/
Post by Hisham
But I think adding a warning message when an unversion l
ib/luarocks/rocks dir is found would be a big improvement.
Not just that, a hint like the one below. And no, I can't be sure all
those are actually 5.3 rocks.
Post by Hisham
If your rocks tree lives at /usr/local/lib/luarocks/rocks or
$HOME/.luarocks/rocks, I believe simply renaming the "rocks" directory
to "rocks-5.3" should make LuaRocks 3 pick it up. Could you give that
a try?
Yes, it works, thanks.
Post by Hisham
Out of curiosity, what are the contents of
/usr/local/etc/luarocks/config-5.3.lua ?
rocks_trees = {
{ name = [[user]], root = home..[[/.luarocks]] },
{ name = [[system]], root = [[/usr/local]] }
}

Now that the binary works, can it be used to install itself as a rock?



-- Dirk

Loading...