Skip to content

Commit 83de3af

Browse files
committed
ci: add merge action
1 parent 70895c1 commit 83de3af

2 files changed

Lines changed: 68 additions & 1 deletion

File tree

.github/merge_to_stable.yml

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: Manual Merge Develop to Stable
2+
3+
on:
4+
workflow_dispatch:
5+
inputs:
6+
reason:
7+
description: 'Merge reason (e.g., "Monthly Release Candidate" or "Hotfix Merge")'
8+
required: false
9+
default: 'Standard merge from develop to stable'
10+
11+
jobs:
12+
merge_branches:
13+
runs-on: ubuntu-latest
14+
15+
permissions:
16+
contents: write
17+
18+
steps:
19+
- name: Checkout stable branch
20+
uses: actions/checkout@v4
21+
with:
22+
ref: stable
23+
fetch-depth: 0
24+
25+
- name: Configure Git User
26+
run: |
27+
git config user.name "GitHub Actions Bot"
28+
git config user.email "github-actions[bot]@users.noreply.github.com"
29+
30+
- name: Merge develop into stable
31+
id: merge
32+
run: |
33+
git fetch origin develop
34+
35+
git merge origin/develop -m "Merge branch 'develop' into stable [Automated Merge]"
36+
37+
if [ $? -eq 0 ]; then
38+
echo "merge_status=success" >> $GITHUB_OUTPUT
39+
else
40+
echo "merge_status=failure" >> $GITHUB_OUTPUT
41+
exit 1
42+
fi
43+
44+
- name: Push merged stable branch
45+
if: steps.merge.outputs.merge_status == 'success'
46+
run: git push origin stable
47+
48+
- name: Notify on Merge Failure
49+
if: steps.merge.outputs.merge_status == 'failure'
50+
run: |
51+
echo "::error::Merge from develop to stable failed due to conflicts. Please resolve manually."

release-please-config.json

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,22 @@
1515
"bump-minor-pre-major": true,
1616
"bump-patch-for-minor-pre-major": true,
1717
"packages": {
18-
".": {}
18+
".": {
19+
"default-branch": "main",
20+
"changelog-sections": [
21+
{ "type": "change", "section": "Changes" },
22+
{ "type": "feat", "section": "Features" },
23+
{ "type": "fix", "section": "Bug Fixes" },
24+
{ "type": "revert", "section": "Reverts" },
25+
{ "type": "docs", "section": "Documentation", "hidden": true },
26+
{ "type": "perf", "section": "Performance Improvements", "hidden": true },
27+
{ "type": "chore", "section": "Miscellaneous Chores", "hidden": true },
28+
{ "type": "test", "section": "Tests", "hidden": true },
29+
{ "type": "style", "section": "Styles", "hidden": true },
30+
{ "type": "refactor", "section": "Code Refactoring", "hidden": true },
31+
{ "type": "ci", "section": "Continuous Integration", "hidden": true }
32+
],
33+
"include-component-in-tag": false
34+
}
1935
}
2036
}

0 commit comments

Comments
 (0)