diff options
| author | Peter Bacon Darwin | 2014-03-12 19:22:32 +0000 | 
|---|---|---|
| committer | Peter Bacon Darwin | 2014-03-12 19:22:32 +0000 | 
| commit | edad4e63dff0ca0b19a264fc17e8b6a5315dfb04 (patch) | |
| tree | 641f40e0e158f0ff974c608509572fed5f09d081 | |
| parent | f684cb09a56d44c0814eda7e1613ecf4d2c5da15 (diff) | |
| download | angular.js-edad4e63dff0ca0b19a264fc17e8b6a5315dfb04.tar.bz2 | |
chore(version-info): better error msg if not tags
| -rw-r--r-- | lib/versions/version-info.js | 6 | 
1 files changed, 6 insertions, 0 deletions
| diff --git a/lib/versions/version-info.js b/lib/versions/version-info.js index 588f1865..90175fc9 100644 --- a/lib/versions/version-info.js +++ b/lib/versions/version-info.js @@ -136,6 +136,12 @@ var getSnapshotVersion = function() {      })      .last(); +  if ( !version ) { +    throw new Error("No valid versions can be found that match the current branch (" + +      currentPackage.branchVersion + ").\n" + +      "Try running `git fetch -t` to download the tags from the repository."); +  } +    // We need to clone to ensure that we are not modifying another version    version = semver(version.raw); | 
