improved command / arguments processing