Check project directory before processing args

Patch stops the "Searching for Board description..." message occuring
before the "No project found in this directory." message if we try to
build outside of a valid project directory.