diff options
author | Kuang-che Wu <kcwu@chromium.org> | 2019-11-25 12:37:55 +0800 |
---|---|---|
committer | Mike Frysinger <vapier@google.com> | 2019-11-25 20:12:34 +0000 |
commit | 6856f98467aa5c98085cdee02587dbab984cebb1 (patch) | |
tree | 1107564123796e6e099eae47c4912cee6b40986a /setup.py | |
parent | 34bc5712eb7e09f9fc5b39ae78786775ad3023e8 (diff) | |
download | git-repo-6856f98467aa5c98085cdee02587dbab984cebb1.tar.gz |
Fix repo mirror with --current-branch
Before a2cd6aeae8, "repo mirror with --current-branch" fetches git data
using command
git fetch --progress --update-head-ok cros --tags
No refspec is specified, thus it fetches default refspec, which is +refs/heads/*:refs/heads/*
After a2cd6aeae8, the fetch command became
git fetch --progress --update-head-ok cros --tags +refs/tags/*:refs/tags/*
It did not only add tags refspec, but also suppressed the fetching of default refspec.
In other words, repo mirrors doesn't work if current_branch_only=True.
This CL explicitly adds the default refspec to command line if none is
specified.
Bug: https://crbug.com/gerrit/11990
Change-Id: Iadcf7b9aa50f53c47132cfe6c53b3fb2076ebca2
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/246632
Reviewed-by: David Pursehouse <dpursehouse@collab.net>
Reviewed-by: Mike Frysinger <vapier@google.com>
Tested-by: Kuang-che Wu <kcwu@chromium.org>
Diffstat (limited to 'setup.py')
0 files changed, 0 insertions, 0 deletions