factor our command line portion