improve command line option parsing