Fix repo mirror with --current-branch
Before a2cd6aea, "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 a2cd6aea, 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>
Loading
Please register or sign in to comment