Skip to content

Commit 4b53f52

Browse files
committed
Be more specific for commit sentence in the spring-cherry-pick
1 parent 468a113 commit 4b53f52

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

.github/workflows/spring-cherry-pick.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ env:
1313
jobs:
1414
cherry-pick:
1515
runs-on: ubuntu-latest
16-
if: contains(github.event.head_commit.message, 'auto-cherry-pick')
16+
if: contains(github.event.head_commit.message, 'Auto-cherry-pick to')
1717
steps:
1818

1919
- uses: actions/checkout@v4
@@ -25,8 +25,8 @@ jobs:
2525
run: |
2626
git config --global user.name 'Spring Builds'
2727
git config --global user.email '[email protected]'
28-
branches=$(echo '${{ github.event.head_commit.message }}' | grep -i auto-cherry-pick | grep -o1 -E "([0-9]+\.[0-9]+\.x)")
29-
branchCommitMessage=$(echo '${{ github.event.head_commit.message }}' | grep -v -i auto-cherry-pick)
28+
branches=$(echo '${{ github.event.head_commit.message }}' | grep 'Auto-cherry-pick to' | grep -o1 -E "([0-9]+\.[0-9]+\.x)")
29+
branchCommitMessage=$(echo '${{ github.event.head_commit.message }}' | grep -v 'Auto-cherry-pick to')
3030
for branch in $branches
3131
do
3232
git checkout $branch

0 commit comments

Comments
 (0)