Descend from root of project when checking against gitignore.

Previously ascended the filesystem from the location of the file being checked. More typically, .gitignore will exist at the root of the project, so this is a performance enhancement.