Advertisement
teru

Untitled

Sep 24th, 2012
209
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.36 KB | None | 0 0
  1. while not bExit do
  2.     write( shell.dir() .. "> " )
  3.  
  4.     local sLine = read( nil, tCommandHistory )
  5.     table.insert( tCommandHistory, sLine )
  6.     runLine( sLine )
  7. end
  8.  
  9. -- If this is the toplevel shell, run the shutdown program
  10. if parentShell == nil then
  11.     if shell.resolveProgram( "shutdown" ) then
  12.         shell.run( "shutdown" )
  13.     end
  14.     os.shutdown() -- just in case
  15. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement