how to build a command line interface tool using python