Allow an options instance to be passed to main().  Closes #111