You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# Heuristic: assume the companion PR has a common merge ancestor with master
54
+
# in its last N commits.
55
+
merge_ancestor_max_depth=256
53
56
set +x
54
57
58
+
merge_remote_ref() {
59
+
local remote="$1"
60
+
local ref="$2"
61
+
local repo="$3"
62
+
local pr_number="$4"
63
+
local message="$5"
64
+
65
+
git show-ref "$remote"/"$ref"
66
+
67
+
local merge_exit_code
68
+
git merge \
69
+
"$remote"/"$ref" \
70
+
--verbose \
71
+
--no-edit \
72
+
-m "$message" \
73
+
|| merge_exit_code=$?
74
+
75
+
if [ "${merge_exit_code:-0}"!= 0 ];then
76
+
echo"
77
+
Failed to merge $ref into $repo#$pr_number after fetching its last $merge_ancestor_max_depth commits.
78
+
79
+
This problem can happen if:
80
+
81
+
- $repo#$pr_number has conflicts with master. To solve this problem you should merge master into the PR, solve the conflicts and push.
82
+
83
+
OR
84
+
85
+
- $repo#$pr_number is ahead of master by more than $merge_ancestor_max_depth commits. To solve this you can merge master into the branch locally and push.
86
+
"
87
+
exit$merge_exit_code
88
+
fi
89
+
}
90
+
55
91
our_crates=()
56
92
discover_our_crates() {
57
93
# workaround for early exits not being detected in command substitution
0 commit comments