Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function skeleton(path)
- local tmp_path=""
- for comp in string.gmatch(path,"(.-)/") do
- tmp_path=tmp_path.."/"..comp
- if not fs.exists(tmp_path) then fs.makeDir(tmp_path) end
- end
- end
- local args={...}
- local path=args[1]
- local over=args[2]
- local repo="Stary2001/ArchMine"
- if not fs.exists(path) or over then
- local page=http.get("https://raw.github.com/"..repo.."/master/"..path)
- if page then
- local content=page.readAll()
- page.close()
- skeleton(fpath)
- local f=fs.open(fpath,"w")
- if f and content then
- f.write(content)
- f.close()
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment