File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -62,7 +62,11 @@ for branch in "${(@k)repos}"; do
6262 else
6363 # Look for a cached remote-tracking ref carrying the integration history.
6464 remote_ref=" "
65- for candidate in " refs/remotes/${monorepo_remote} /${branch} " " refs/remotes/origin/${branch} " ; do
65+ candidates=(" refs/remotes/${monorepo_remote} /${branch} " )
66+ if [[ " $monorepo_remote " != " origin" ]]; then
67+ candidates+=(" refs/remotes/origin/${branch} " )
68+ fi
69+ for candidate in " ${candidates[@]} " ; do
6670 if git show-ref --verify --quiet " $candidate " ; then
6771 remote_ref=" $candidate "
6872 break
@@ -86,7 +90,9 @@ for branch in "${(@k)repos}"; do
8690 git -c merge.directoryRenames=true pull --no-ff " $upstream "
8791
8892 after=$( git rev-parse HEAD)
89- updated+=(" $branch " )
93+ if [[ " $before " != " $after " ]]; then
94+ updated+=(" $branch " )
95+ fi
9096done
9197
9298git switch " $start_branch "
You can’t perform that action at this time.
0 commit comments