move command line state into a separate file