-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathbootstrap.lua
More file actions
40 lines (31 loc) · 952 Bytes
/
Copy pathbootstrap.lua
File metadata and controls
40 lines (31 loc) · 952 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
--[[
turtle bootstrap
simple program to get a bunch of other programs in one run
of 'pastebin get'
Usage:
> pastebin get 55tqszpw bootstrap
> bootstrap
--]]
http_runs = {
["pastebin"] = {
-- github loader
["caMmH484"] = "github",
},
-- make sure to use the right URL for raw.github.com
["github"] = {
-- grab the github bootstrap
["seriallos/computercraft/master/boot2.lua"] = "boot2",
},
}
for service, list in pairs( http_runs ) do
for id, program in pairs( list ) do
print( "Downloading "..program.." from "..service )
shell.run( service, "get", id, program )
end
end
-- run the bootstrapper from github
-- second level of bootstrap is so the files on pastebin can be pretty static.
-- github is way easier to manage from the command line. i don't want to
-- constantly be futzing with the pastebin site or API.
-- git add .; git commit -m "blah"; git push # so much better!
shell.run( "boot2" )