File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11name : Release Automation
22
33on :
4- push :
5- branches :
6- - master
4+ pull_request :
5+ types : [closed]
76
87jobs :
98 create_release :
10- # We only run it for merge commits from branches release/*
11- if : startsWith(github.event.head_commit.message, 'Merge pull request') && contains(github.event.head_commit.message, 'from release/')
9+ # We only run it for merged PRs from a release/* branch into master.
10+ if : |
11+ github.event.pull_request.merged == true &&
12+ github.event.pull_request.base.ref == 'master' &&
13+ startsWith(github.event.pull_request.head.ref, 'release/')
1214 runs-on : ubuntu-latest
1315 permissions :
1416 contents : write # to create tags and releases
1719 - name : Checkout code
1820 uses : actions/checkout@v4
1921 with :
20- # I need a complete history to read the tags and create a PR
22+ # We check out the master branch, which is the state after the merge.
23+ ref : ' master'
2124 fetch-depth : 0
2225
2326 - name : Get Version
You can’t perform that action at this time.
0 commit comments