Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import rdstdin
- import os
- import strutils
- proc mainLoop() =
- var bye = "Bye bye!"
- while true:
- var input = readLineFromStdin("> ")
- case input
- of "quit":
- echo(bye)
- break
- of "q":
- echo(bye)
- break
- else:
- echo(execShellCmd("hdfs dfs -$1" % [input]))
- mainLoop()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement