chore(scripts): fix cherry-pick check in check_commit_metadata.sh (#13980)

This commit is contained in:
Mathias Fredriksson
2024-07-23 06:49:29 +00:00
committed by GitHub
parent a8e6e89f65
commit 5a4dbcfc02
+6
View File
@@ -126,6 +126,7 @@ main() {
log "Found renamed cherry-pick commit ${commit1} -> ${renamed}"
renamed_cherry_pick_commits[${commit1}]=${renamed}
renamed_cherry_pick_commits[${renamed}]=${commit1}
i=$((i - 1))
continue
fi
@@ -147,6 +148,11 @@ main() {
log "Found matching cherry-pick commit ${commit} -> ${renamed_cherry_pick_commits[${commit}]}"
done
# Merge the two maps.
for commit in "${!renamed_cherry_pick_commits[@]}"; do
cherry_pick_commits[${commit}]=${renamed_cherry_pick_commits[${commit}]}
done
# Get abbreviated and full commit hashes and titles for each commit.
git_log_out="$(git log --no-merges --left-right --pretty=format:"%m %h %H %s" "${range}")"
if [[ -z ${git_log_out} ]]; then