mirror of
https://github.com/S4mpsa/InfOS.git
synced 2025-09-07 14:15:37 -04:00
Simplifying setup
This commit is contained in:
parent
d995a8f670
commit
c3a0326631
35
setup.lua
Normal file
35
setup.lua
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
-- wget https://raw.githubusercontent.com/gordominossi/InfOS/master/setup.lua -f
|
||||||
|
local shell = require("shell")
|
||||||
|
|
||||||
|
local tarMan = "https://raw.githubusercontent.com/mpmxyz/ocprograms/master/usr/man/tar.man"
|
||||||
|
local tarBin = "https://raw.githubusercontent.com/mpmxyz/ocprograms/master/home/bin/tar.lua"
|
||||||
|
|
||||||
|
shell.setWorkingDirectory("/usr/man")
|
||||||
|
shell.execute("wget -fq " .. tarMan)
|
||||||
|
shell.setWorkingDirectory("/bin")
|
||||||
|
shell.execute("wget -fq " .. tarBin)
|
||||||
|
|
||||||
|
local InfOS = "https://github.com/gordominossi/InfOS/releases/download/v0.1/InfOS.tar"
|
||||||
|
|
||||||
|
shell.setWorkingDirectory("/home")
|
||||||
|
if not shell.resolve("/home/lib") then
|
||||||
|
shell.execute("mkdir lib")
|
||||||
|
end
|
||||||
|
if not shell.resolve("/home/InfOS") then
|
||||||
|
shell.execute("mkdir InfOS")
|
||||||
|
end
|
||||||
|
|
||||||
|
shell.setWorkingDirectory("/home/InfOS")
|
||||||
|
print("\nUpdating InfOS")
|
||||||
|
shell.execute("wget -fq " .. InfOS .. " -f")
|
||||||
|
print("...")
|
||||||
|
shell.execute("tar -xf InfOS.tar")
|
||||||
|
shell.execute("rm -f InfOS.tar")
|
||||||
|
|
||||||
|
shell.setWorkingDirectory("/home/")
|
||||||
|
shell.execute("rm -f .shrc")
|
||||||
|
shell.execute("cp InfOS/.shrc .shrc")
|
||||||
|
shell.execute("rm -f setup.lua")
|
||||||
|
shell.execute("cp InfOS/setup.lua setup.lua")
|
||||||
|
|
||||||
|
print("Success!\n")
|
Loading…
x
Reference in New Issue
Block a user