conver string commands to array