branching: don't push branches and tags in a single command
The command 'git push --tags ${review_remote} ${branch}' is trying to push the branch and tag at the same time, and as a side effect is re-pushing all other known tags. Upstream servers are now consistently rejecting this. Either they only accept a single branch or tag per push, or they reject duplicate tags that they already have, even if unchanged. Change the code to push the branch and tag independently. Closes-bug: 1952472 Change-Id: If99123b1eae823ea05ee2b2c80f891cb189e18d3 Signed-off-by: Scott Little <scott.little@windriver.com>
This commit is contained in:
parent
b2427a1ff7
commit
078d3cb038
@ -234,12 +234,16 @@ for subgit in $SUBGITS; do
|
||||
$DRY_RUN_CMD git config --local --replace-all "branch.${branch}.merge" refs/heads/${branch} && \
|
||||
$DRY_RUN_CMD git review --topic="${branch}"
|
||||
else
|
||||
echo "git push --tags ${review_remote} ${branch} $DRY_RUN"
|
||||
git push --tags ${review_remote} ${branch} $DRY_RUN
|
||||
echo "git push ${review_remote} ${branch}:${branch} $DRY_RUN"
|
||||
git push ${review_remote} ${branch}:${branch} $DRY_RUN
|
||||
echo "git push ${review_remote} ${tag}:${tag} $DRY_RUN"
|
||||
git push ${review_remote} ${tag}:${tag} $DRY_RUN
|
||||
fi
|
||||
else
|
||||
echo "git push --tags --set-upstream ${remote} ${branch} $DRY_RUN"
|
||||
git push --tags --set-upstream ${remote} ${branch} $DRY_RUN
|
||||
echo "git push ${remote} ${branch}:${branch} $DRY_RUN"
|
||||
git push ${remote} ${branch}:${branch} $DRY_RUN
|
||||
echo "git push ${remote} ${tag}:${tag} $DRY_RUN"
|
||||
git push ${remote} ${tag}:${tag} $DRY_RUN
|
||||
fi
|
||||
|
||||
if [ $? != 0 ] ; then
|
||||
|
Loading…
x
Reference in New Issue
Block a user