common/install.lua
authorOlav Bakke Svendsen <mail@olavbs.no>
Wed, 15 May 2024 17:00:57 +0000 (19:00 +0200)
committerOlav Bakke Svendsen <mail@olavbs.no>
Wed, 15 May 2024 17:00:57 +0000 (19:00 +0200)
common/install.lua

index 0fe416c0df46981154f97f320c7453367a59683b..08934f1047b551b0ba16c89191607c5a5f52a46f 100644 (file)
@@ -2,10 +2,11 @@
 -- looks for package-file in git repo and runs dl.lua on every line
 -- usage:
 -- install repo:[tag] remote/path
-
+local args = {...}
 local tmp = textutils.serialize(math.random(100000,999999))
 shell.run("dl "..args[1].." "..args[2].."/package:"..tmp)
-for line in lines(tmp) do
+local file = fs.open(tmp, "r")
+for line in file.readLine do
   shell.run("dl "..line)
 end
 fs.delete(tmp)