diff options
Diffstat (limited to 'Demo/pdist/mac.py')
-rwxr-xr-x | Demo/pdist/mac.py | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/Demo/pdist/mac.py b/Demo/pdist/mac.py index 107113c..61cff09 100755 --- a/Demo/pdist/mac.py +++ b/Demo/pdist/mac.py @@ -1,14 +1,18 @@ import sys -import string import rcvs +def raw_input(prompt): + sys.stdout.write(prompt) + sys.stdout.flush() + return sys.stdin.readline() + def main(): while 1: try: line = raw_input('$ ') except EOFError: break - words = string.split(line) + words = line.split() if not words: continue if words[0] != 'rcvs': @@ -16,4 +20,5 @@ def main(): sys.argv = words rcvs.main() -main() +if __name__ == '__main__': + main() |