Sirshark10

DevShell (Reupload)

Jul 16th, 2017
267
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. --Alternative shell from CraftOS shell
  2.  
  3. termutils = {}
  4.  
  5. termutils.clear = function()
  6. term.clear()
  7. term.setCursorPos(1,1)
  8. end
  9.  
  10. termutils.clearColor = function()
  11. term.setTextColor(colors.white)
  12. term.setBackgroundColor(colors.black)
  13. end
  14.  
  15. function input()
  16. term.setTextColor(colors.blue)
  17. local dir = shell.dir().."/"..">"
  18. write(dir)
  19. termutils.clearColor()
  20. command = io.read()
  21. end
  22.  
  23. termutils.clear()
  24. print("DevShell by WattDev(OR WHOEVER AM I) V1.0")
  25. while true do
  26. input()
  27. shell.run(command)
  28. end
Advertisement
Add Comment
Please, Sign In to add comment