Improve command line parsing