Skip to content

Commit ff03bf4

Browse files
committed
feat: create PR from main -> release
With the outstanding renaming of main -> release and dev -> main this workflow will create a pull request every time a PR is merged into main, our then main development branch. I tested this workflow from a temporary branch called release-test. See an example PR that was created by this workflow here: #478
1 parent 40bb9f3 commit ff03bf4

File tree

2 files changed

+36
-1
lines changed

2 files changed

+36
-1
lines changed
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Create Release PR
2+
on:
3+
push:
4+
branches: [ main ]
5+
6+
permissions:
7+
contents: write
8+
pull-requests: write
9+
10+
jobs:
11+
release:
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v4
15+
16+
- name: Semantic Release Versioning
17+
uses: cycjimmy/semantic-release-action@v4
18+
with:
19+
extra_plugins: |
20+
@semantic-release/commit-analyzer
21+
@semantic-release/release-notes-generator
22+
@semantic-release/github
23+
env:
24+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
25+
26+
- name: Create Release PR
27+
env:
28+
GH_TOKEN: ${{ secrets.GHA_CREATE_PR }}
29+
run: |
30+
gh pr create \
31+
--base release \
32+
--head main \
33+
--title "chore: new release" \
34+
--body "Automated PR from main to release" \
35+
--label "automated pr"

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "hypercert-app",
3-
"version": "0.1.0",
3+
"version": "0.1.1",
44
"private": true,
55
"scripts": {
66
"dev": "next dev",

0 commit comments

Comments
 (0)