Update readme and code for running from command line.