Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- DEL 1.0 | Written by DiabolusNeil
- -- Minimum Requirement: Normal Computer
- -- Last Updated 11/2/2013
- local tArgs = {...}
- if #tArgs < 1 then
- print("Usage: <path1> [path2] [etc]")
- return
- end
- local sPath = tArgs
- for i = 1, #sPath do
- if fs.exists(sPath[i]) then
- print("Are you sure you want to delete \""..sPath[i].."\"? Y/N")
- while true do
- local event, key = os.pullEvent("key")
- if key == keys.y then
- fs.delete(sPath[i])
- print("File deleted")
- break
- elseif key == keys.n then
- print("File not deleted")
- break
- end
- end
- else
- print("Sorry, file \""..sPath[i].."\" does not exist")
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment