PyCli : Need some reference to good books or tutorials on pycli

Michael Torrie torriem at
Fri Sep 26 16:58:43 CEST 2014

On 09/26/2014 06:54 AM, vijnaana at wrote:
> Hi Folks,
> I need to develop a CLI (PyCli or similar)on Linux.
> To be more specific to develop Quagga(open source routing software) like
> commands using python instead of C.
> Need some good reference material for the same.
> P.S google didn't help

Wait, are you asking about making a command-line interface in Python?
If so, then there are a number of aspects you can google for:
- command line argument parsing.  See python docs on argparse
- A read/eval print loop using custom keywords and syntax, if you want
your program to be interactive.
   - you'll need to use readline to handle line editing
   - something to parse line input.  PyParsing perhaps.  Or some other
lexical parser, or manually do the parsing you need to do with .split()
or regular expressions.
   - possibly curses for doing screen output, though print() is probably

Except for pyparsing everything is in the standard library.

More information about the Python-list mailing list