Skip to content

Commit ff0b98d

Browse files
committed
Add automatic-releases workflow
Signed-off-by: Geert Eltink <[email protected]>
1 parent bcd86e4 commit ff0b98d

File tree

1 file changed

+71
-0
lines changed

1 file changed

+71
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
# Alternate workflow example.
2+
# This one is identical to the one in release-on-milestone.yml, with one change:
3+
# the Release step uses the ORGANIZATION_ADMIN_TOKEN instead, to allow it to
4+
# trigger a release workflow event. This is useful if you have other actions
5+
# that intercept that event.
6+
7+
name: "Automatic Releases"
8+
9+
on:
10+
milestone:
11+
types:
12+
- "closed"
13+
14+
jobs:
15+
release:
16+
name: "GIT tag, release & create merge-up PR"
17+
runs-on: ubuntu-latest
18+
19+
steps:
20+
- name: "Checkout"
21+
uses: "actions/checkout@v2"
22+
23+
- name: "Release"
24+
uses: "laminas/automatic-releases@v1"
25+
with:
26+
command-name: "laminas:automatic-releases:release"
27+
env:
28+
"GITHUB_TOKEN": ${{ secrets.ORGANIZATION_ADMIN_TOKEN }}
29+
"SIGNING_SECRET_KEY": ${{ secrets.SIGNING_SECRET_KEY }}
30+
"GIT_AUTHOR_NAME": ${{ secrets.GIT_AUTHOR_NAME }}
31+
"GIT_AUTHOR_EMAIL": ${{ secrets.GIT_AUTHOR_EMAIL }}
32+
33+
- name: "Create Merge-Up Pull Request"
34+
uses: "laminas/automatic-releases@v1"
35+
with:
36+
command-name: "laminas:automatic-releases:create-merge-up-pull-request"
37+
env:
38+
"GITHUB_TOKEN": ${{ secrets.GITHUB_TOKEN }}
39+
"SIGNING_SECRET_KEY": ${{ secrets.SIGNING_SECRET_KEY }}
40+
"GIT_AUTHOR_NAME": ${{ secrets.GIT_AUTHOR_NAME }}
41+
"GIT_AUTHOR_EMAIL": ${{ secrets.GIT_AUTHOR_EMAIL }}
42+
43+
- name: "Create and/or Switch to new Release Branch"
44+
uses: "laminas/automatic-releases@v1"
45+
with:
46+
command-name: "laminas:automatic-releases:switch-default-branch-to-next-minor"
47+
env:
48+
"GITHUB_TOKEN": ${{ secrets.ORGANIZATION_ADMIN_TOKEN }}
49+
"SIGNING_SECRET_KEY": ${{ secrets.SIGNING_SECRET_KEY }}
50+
"GIT_AUTHOR_NAME": ${{ secrets.GIT_AUTHOR_NAME }}
51+
"GIT_AUTHOR_EMAIL": ${{ secrets.GIT_AUTHOR_EMAIL }}
52+
53+
- name: "Bump Changelog Version On Originating Release Branch"
54+
uses: "laminas/automatic-releases@v1"
55+
with:
56+
command-name: "laminas:automatic-releases:bump-changelog"
57+
env:
58+
"GITHUB_TOKEN": ${{ secrets.GITHUB_TOKEN }}
59+
"SIGNING_SECRET_KEY": ${{ secrets.SIGNING_SECRET_KEY }}
60+
"GIT_AUTHOR_NAME": ${{ secrets.GIT_AUTHOR_NAME }}
61+
"GIT_AUTHOR_EMAIL": ${{ secrets.GIT_AUTHOR_EMAIL }}
62+
63+
- name: "Create new milestones"
64+
uses: "laminas/automatic-releases@v1"
65+
with:
66+
command-name: "laminas:automatic-releases:create-milestones"
67+
env:
68+
"GITHUB_TOKEN": ${{ secrets.GITHUB_TOKEN }}
69+
"SIGNING_SECRET_KEY": ${{ secrets.SIGNING_SECRET_KEY }}
70+
"GIT_AUTHOR_NAME": ${{ secrets.GIT_AUTHOR_NAME }}
71+
"GIT_AUTHOR_EMAIL": ${{ secrets.GIT_AUTHOR_EMAIL }}

0 commit comments

Comments
 (0)