summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthieu Coudron <mcoudron@hotmail.com>2022-09-06 23:43:12 +0200
committerMatthieu Coudron <mcoudron@hotmail.com>2022-09-11 21:25:44 +0200
commitcbcb40589c1ebcaea8ff741e6431a2050c5e8caf (patch)
tree3d38097c58944f5b4eb98e7680f49b5eade7af27
parenta7fb06c2da708e39169059a797ba7c0cb8433256 (diff)
update-luarocks-package: better way to specify lua version
instead of running luarocks with the requested interpreter, we can ask any interpreter to search for a specific version via --lua-version. It avoids building/running different luarocks-nix just for that. use tagged release of nvim-cmp
-rw-r--r--maintainers/scripts/luarocks-packages.csv22
-rwxr-xr-xmaintainers/scripts/update-luarocks-packages13
2 files changed, 17 insertions, 18 deletions
diff --git a/maintainers/scripts/luarocks-packages.csv b/maintainers/scripts/luarocks-packages.csv
index e41e8a162546..6e867e7fc539 100644
--- a/maintainers/scripts/luarocks-packages.csv
+++ b/maintainers/scripts/luarocks-packages.csv
@@ -1,6 +1,6 @@
name,src,ref,server,version,luaversion,maintainers
alt-getopt,,,,,,arobyn
-bit32,,,,5.3.0-1,lua5_1,lblasc
+bit32,,,,5.3.0-1,5.1,lblasc
argparse,https://github.com/luarocks/argparse.git,,,,,
basexx,https://github.com/teto/basexx.git,,,,,
binaryheap,https://github.com/Tieske/binaryheap.lua,,,,,vcunat
@@ -12,20 +12,20 @@ cosmo,,,,,,marsam
coxpcall,,,,1.17.0-1,,
cqueues,,,,,,vcunat
cyrussasl,https://github.com/JorjBauer/lua-cyrussasl.git,,,,,
-digestif,https://github.com/astoff/digestif.git,,,0.2-1,lua5_3,
+digestif,https://github.com/astoff/digestif.git,,,0.2-1,5.3,
dkjson,,,,,,
fifo,,,,,,
fluent,,,,,,alerque
-gitsigns.nvim,https://github.com/lewis6991/gitsigns.nvim.git,,,,lua5_1,
+gitsigns.nvim,https://github.com/lewis6991/gitsigns.nvim.git,,,,5.1,
http,,,,0.3-0,,vcunat
inspect,,,,,,
ldbus,,,http://luarocks.org/dev,,,
ldoc,https://github.com/stevedonovan/LDoc.git,,,,,
lgi,,,,,,
linenoise,https://github.com/hoelzro/lua-linenoise.git,,,,,
-ljsyscall,,,,,lua5_1,lblasc
-lmathx,,,,,lua5_3,alexshpilkin
-lmpfrlib,,,,,lua5_3,alexshpilkin
+ljsyscall,,,,,5.1,lblasc
+lmathx,,,,,5.3,alexshpilkin
+lmpfrlib,,,,,5.3,alexshpilkin
loadkit,,,,,,alerque
lpeg,,,,,,vyp
lpeg_patterns,,,,,,
@@ -45,7 +45,7 @@ lua-resty-jwt,,,,,,
lua-resty-openidc,,,,,,
lua-resty-openssl,,,,,,
lua-resty-session,,,,,,
-lua-subprocess,https://github.com/0x0ade/lua-subprocess,,,,lua5_1,scoder12
+lua-subprocess,https://github.com/0x0ade/lua-subprocess,,,,5.1,scoder12
lua-term,,,,,,
lua-toml,,,,,,
lua-zlib,,,,,,koral
@@ -63,7 +63,7 @@ luaexpat,,,,1.4.1-1,,arobyn flosse
luaffi,,,http://luarocks.org/dev,,,
luafilesystem,,,,1.7.0-2,,flosse
lualogging,,,,,,
-luaossl,,,,,lua5_1,
+luaossl,,,,,5.1,
luaposix,,,,34.1.1-1,,vyp lblasc
luarepl,,,,,,
luasec,,,,,,flosse
@@ -71,7 +71,7 @@ luasocket,,,,,,
luasql-sqlite3,,,,,,vyp
luassert,,,,,,
luasystem,,,,,,
-luaunbound,,,,,
+luaunbound,,,,,,
luaunit,,,,,,lockejan
luautf8,,,,,,pstn
luazip,,,,,,
@@ -84,9 +84,11 @@ mediator_lua,,,,,,
mpack,,,,,,
moonscript,https://github.com/leafo/moonscript.git,dev-1,,,,arobyn
nvim-client,https://github.com/neovim/lua-client.git,,,,,
+nvim-cmp,,,,,
penlight,https://github.com/lunarmodules/Penlight.git,,,,,alerque
-plenary.nvim,https://github.com/nvim-lua/plenary.nvim.git,,,,lua5_1,
+plenary.nvim,https://github.com/nvim-lua/plenary.nvim.git,,,,5.1,
rapidjson,https://github.com/xpol/lua-rapidjson.git,,,,,
+rest.nvim,,,,,5.1,teto
readline,,,,,,
say,https://github.com/Olivine-Labs/say.git,,,,,
serpent,,,,,,lockejan
diff --git a/maintainers/scripts/update-luarocks-packages b/maintainers/scripts/update-luarocks-packages
index cab63ca44e38..f34aa53626da 100755
--- a/maintainers/scripts/update-luarocks-packages
+++ b/maintainers/scripts/update-luarocks-packages
@@ -161,7 +161,10 @@ def generate_pkg_nix(plug: LuaPlugin):
custom_env = os.environ.copy()
custom_env['LUAROCKS_CONFIG'] = LUAROCKS_CONFIG
- cmd = [ "luarocks", "nix"]
+ # we add --dev else luarocks wont find all the "scm" (=dev) versions of the
+ # packages
+ # , "--dev"
+ cmd = [ "luarocks", "nix" ]
if plug.maintainers:
cmd.append(f"--maintainers={plug.maintainers}")
@@ -185,13 +188,7 @@ def generate_pkg_nix(plug: LuaPlugin):
cmd.append(f"--only-server={plug.server}")
if plug.luaversion:
- with CleanEnvironment():
- local_pkgs = str(ROOT.resolve())
- cmd2 = ["nix-build", "--no-out-link", local_pkgs, "-A", f"{plug.luaversion}"]
-
- log.debug("running %s", ' '.join(cmd2))
- lua_drv_path=subprocess.check_output(cmd2, text=True).strip()
- cmd.append(f"--lua-dir={lua_drv_path}/bin")
+ cmd.append(f"--lua-version={plug.luaversion}")
log.debug("running %s", ' '.join(cmd))