命令行接口(Command Line Interface,简称CLI)
# -*- coding: utf-8 -*- # @File : fire_CLI_demo.py # @Date : 2018-06-03 import fire class Person(object): def hello(self, name="world"): print("hell %s"% name) if __name__ == '__main__': fire.Fire(Person) # 运行命令: python fire_CLI_demo.py hello