Escape spaces and apostrophes in filepaths.

This changes `/Volumes/myname's home/my-project/test.php` to `/Volumes/myname\'s\ home/my-project/test.php` so phpcs, etc. don't break while editing files with spaces or apostrophes in their path.