rewrite how I parse the options