Improved command line arguments parsing.