Fixed paths for windows compatability, fixed linting issues, fixed minor doc bug

Paths weren't working correctly on windows so I fixed everything up to make sure that all paths are normalized and joined so they'll work on *nix and windows

Linted the file also and fixed up any issues reported by jshint

Finally fixed a typo in the docs for retrieve target