def __init__(self):
try:
self.read_config()
except:
c = {}
c['url'] = raw_input(u"Enter server hostname or IP address: ")
c['username'] = raw_input(u"Enter user name: ")
c['password'] = getpass(u"Enter password: ")
self.config['credentials'] = c
self.pve = Pveconn(**self.config['credentials'])
if '-c' in sys.argv:
command = sys.argv[sys.argv.index('-c')+1:]
self.parse_command(command)
else:
readline.parse_and_bind("tab: complete")
readline.set_completer(self.complete)
self.wait()
评论列表
文章目录