cli.py 文件源码

python
阅读 31 收藏 0 点赞 0 评论 0

项目:proxmoxsh 作者: timur-enikeev 项目源码 文件源码
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()
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号