(fix) Added respect for whitespace in DIR and CMD

Passing commands containing whitespace such as "make test" works now.