Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local tArg = {...}
- local Action = tArg[1]
- if Action == "Update" then
- elseif Action == "CleanFolder" then
- local Cleans = fs.list(tArg[2])
- for i = 1, #Cleans do
- fs.delete(Cleans[i])
- end
- elseif Action == "RunFolder" then
- local Runs = fs.list(tArg[2])
- for i = 1, #Runs do
- shell.run(fs.combine(tArg[2],Runs[i]))
- end
- elseif Action == "DownloadExternal" then
- local Drive = peripherals.find(tArg[2])
- local Path = Drive.getMountPath()
- local ExItems = fs.list(Path)
- for i = 1, #ExItems do
- fs.copy(fs.combine(Path,ExItems[i]),fs.combine(tArg[3],ExItems[i]))
- end
- end
Add Comment
Please, Sign In to add comment