about summary refs log tree commit diff
path: root/maintainers
diff options
context:
space:
mode:
authorMatthieu Coudron <mcoudron@hotmail.com>2022-05-14 15:53:02 +0200
committerMatthieu Coudron <mcoudron@hotmail.com>2022-06-13 11:17:24 +0200
commit77a0e5f36e758ec62354919bd4dcc28b9eeebe3c (patch)
tree0769dad1049b914b406d00d8909ea66028929335 /maintainers
parent90cd5459a1fd707819b9a3fb9c852beaaac3b79a (diff)
luarocks: 3.8.0 -> 3.9.0
pass the config to the luarocks binary

also bumps luarocks-nix: bump package due to the luarocks rebase
Diffstat (limited to 'maintainers')
-rwxr-xr-xmaintainers/scripts/update-luarocks-packages8
1 files changed, 6 insertions, 2 deletions
diff --git a/maintainers/scripts/update-luarocks-packages b/maintainers/scripts/update-luarocks-packages
index 73a233c5f1037..048068a32e122 100755
--- a/maintainers/scripts/update-luarocks-packages
+++ b/maintainers/scripts/update-luarocks-packages
@@ -158,8 +158,11 @@ def generate_pkg_nix(plug: LuaPlugin):
     Our cache key associates "p.name-p.version" to its rockspec
     '''
     log.debug("Generating nix expression for %s", plug.name)
-    cmd = [ "luarocks", "nix"]
+    custom_env = os.environ.copy()
+    # TODO check
+    custom_env['LUAROCKS_CONFIG'] = LUAROCKS_CONFIG
 
+    cmd = [ "luarocks", "nix"]
 
     if plug.maintainers:
         cmd.append(f"--maintainers={plug.maintainers}")
@@ -194,7 +197,8 @@ def generate_pkg_nix(plug: LuaPlugin):
             cmd.append(f"--lua-dir={lua_drv_path}/bin")
 
     log.debug("running %s", ' '.join(cmd))
-    output = subprocess.check_output(cmd, text=True)
+
+    output = subprocess.check_output(cmd, env=custom_env, text=True)
     output = "callPackage(" + output.strip() + ") {};\n\n"
     return (plug, output)