-#!/usr/bin/python
+#!/usr/bin/python3
import sys, getopt, readline
import pdm.cli
if len(args) < 1:
usage(sys.stderr)
sys.exit(1)
-cl = pdm.cli.replclient(args[0])
+try:
+ cl = pdm.cli.replclient(args[0])
+except Exception as e:
+ sys.stderr.write("%s: %s\n" % (args[0], e))
+ sys.exit(1)
buf = ""
while True:
try:
if buf != "":
- line = raw_input(" ")
+ line = input(" ")
else:
- line = raw_input("% ")
+ line = input("% ")
except EOFError:
break
if line == "":