Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixes the bug where pants doesn't recognize build targets on top-leve…
…l directories. The previous argument parser naively simply checked whether a command-line argument contained a slash (/) or a colon (:). This is a reasonable assumption most of the time, but in the case where a BUILD file is located only one directory deep, (eg, buildroot/folder/BUILD), this makes it impossible to run pants on the target simply by calling (eg) ./pants goal bundle folder. See github issue for example: pantsbuild#159 This fixes it by actually checking to see if a phase with goals is defined by the command-line argument. It still checks before that whether the argument contains a slash or a colon, because that if an argument has those characters it can't mean a goal. But an argument not having those characters doesn't mean it is a goal.
- Loading branch information