fixed wrong escaping and enable -x and -e