clean up options handling and allow options.tokens in addition to options.global