Merge pull request #1927 from dtzWill/fix/fetchgit-HEAD

fetchGit: use "HEAD" as default ref instead of "master"
This commit is contained in:
Shea Levy 2018-02-28 18:44:57 -05:00 committed by GitHub
commit 4a000cbb39
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -79,7 +79,7 @@ GitInfo exportGit(ref<Store> store, const std::string & uri,
ref = "HEAD"s;
}
if (!ref) ref = "master"s;
if (!ref) ref = "HEAD"s;
if (rev != "" && !std::regex_match(rev, revRegex))
throw Error("invalid Git revision '%s'", rev);