Handle recursive globs with build-file-rev

Review Request #2572 - Created Aug. 4, 2015 and submitted

David Turner
benjyw, jsirois, stuhood

Previously, build-file-rev with recursive globs would fail in two ways:
1. cmd_line_spec_parser would mistakenly look for the glob directory
in the filesystem even.

  1. Some relative paths would contain dot components (e.g. ./foo), and
    _realpath_uncached would fail to handle these.

This patch fixes both of these problems.

The recursive glob check had to move inside scan_buildfiles. To do
so, _isdir became a classmethod, so _isfile and _exists changed too,
for consistency.

Ran selected tests (including new tests) manually.

CI running: https://travis-ci.org/pantsbuild/pants/builds/74156071

Eric Ayers
John Sirois
David Turner
John Sirois
David Turner
David Turner
David Turner
Review request changed

Status: Closed (submitted)

Change Summary:

in master at 31cde2e3c14fcaffd79e0a29b80d872b2266b380