Skip to content

Commit 61fdbe2

Browse files
committed
ci/update: fix re-apply commit order
We need to reverse the `rev-list` output so that the commits are re-applied in the correct order; oldest first.
1 parent d709c12 commit 61fdbe2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

.github/workflows/update.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ jobs:
142142
remote="origin/$pr_branch"
143143
author_rxp='^github-actions\[bot\] <41898282+github-actions\[bot\]@users\.noreply\.github\.com>$'
144144
base=$(git rev-list --author="$author_rxp" --max-count=1 "$remote")
145-
commits=( $(git rev-list "$base..$remote") )
145+
commits=( $(git rev-list --reverse "$base..$remote") )
146146
if [[ -n "$commits" ]]; then
147147
echo "Applying ${#commits[@]} commits..."
148148
echo "count=${#commits[@]}" >> $GITHUB_OUTPUT

0 commit comments

Comments
 (0)