first cut implementation of commandline program.