diff --git a/projects/luarocks.org/package.yml b/projects/luarocks.org/package.yml index a8ce15ba..8ec19d20 100644 --- a/projects/luarocks.org/package.yml +++ b/projects/luarocks.org/package.yml @@ -19,11 +19,43 @@ build: - make --jobs {{ hw.concurrency }} install - run: | fix-shebangs.ts luarocks-admin luarocks - sed -i.bak \ + sed -i \ -e 's|\[\[{{prefix}}|debug.getinfo(1).source:match("@?(.*/)") .. \[\[..|g' \ luarocks-admin luarocks - rm luarocks-admin.bak luarocks.bak working-directory: ${{prefix}}/bin + + # luarocks config has fixed paths + - run: | + mv bin tbin + mkdir bin + working-directory: ${{prefix}} + - run: | + cat $PROP >luarocks + cat $PROP >luarocks-admin + chmod +x luarocks luarocks-admin + working-directory: ${{prefix}}/bin + prop: | + #!/bin/sh + + d="$(cd "$(dirname "$0")"/.. && pwd)" + x="$(basename "$0")" + + cat >"$d/etc/luarocks/config-{{deps.lua.org.version.marketing}}.lua" <