Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if not fs.exists("pocke") then
- print("Installing U1 Pre-Alpha")
- else
- print("Updating U1 Pre-Alpha")
- end
- if not http then
- print("HTTP not enabled! Make sure you enable it in the server configuration!")
- end
- function download(url, file)
- print("Downloading "..file)
- local fdl = http.get(url)
- if not fdl then
- print("Failed to connect! Are you connected to the internet?")
- end
- local f = fs.open(file,"w")
- print("Opening file "..file)
- f.write(fdl.readAll())
- f.close()
- print("Written to file "..file)
- end
- download("https://www.dropbox.com/s/k15800l0dkhirmo/startup?dl=1","startup")
- download("https://www.dropbox.com/s/6exvxj3l60vs8r5/os.lua?dl=1","pocke/os.lua")
- download("https://www.dropbox.com/s/hbmt6bf1tjl8z4z/settings?dl=1","pocke/api/settings")
- download("https://www.dropbox.com/s/rxxg8cxhoe83h2o/edge?dl=1","pocke/api/edge")
- download("https://www.dropbox.com/s/48ca6yjrsecsnd7/crash?dl=1","pocke/user/crash")
- download("https://www.dropbox.com/s/i18p42ph8blylfm/settings.cfg?dl=1","pocke/settings.cfg")
- download("https://www.dropbox.com/s/ed57owqqjp53l57/installer?dl=1","pocke/user/updater")
- print("Rebooting.")
- sleep(3)
- os.reboot()
Add Comment
Please, Sign In to add comment