Skip to content

Commit d965245

Browse files
authored
Add release workflow definitions (#43)
1 parent 59013a4 commit d965245

File tree

2 files changed

+51
-0
lines changed

2 files changed

+51
-0
lines changed
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
---
2+
# Workflow to automate creation and updating of release branches
3+
name: Release Branching
4+
5+
# Trigger on tags created by TeamCity
6+
on:
7+
push:
8+
tags:
9+
- '*'
10+
11+
jobs:
12+
branch_release:
13+
if: github.event.created && github.event.sender.login == 'labkey-teamcity'
14+
runs-on: ubuntu-latest
15+
16+
steps:
17+
- name: Checkout
18+
uses: actions/checkout@v2
19+
20+
- name: Create branches and PRs
21+
uses: LabKey/gitHubActions/branch-release@master
22+
with:
23+
github_token: ${{ secrets.GITHUB_TOKEN }}
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
---
2+
# Workflow to automate merging release branches
3+
name: Release Merging
4+
5+
# Trigger on PR approval
6+
on:
7+
pull_request_review:
8+
types:
9+
- submitted
10+
11+
jobs:
12+
merge_release:
13+
if: >
14+
github.event.review.state == 'approved' &&
15+
github.event.pull_request.user.login == 'github-actions[bot]'
16+
runs-on: ubuntu-latest
17+
18+
steps:
19+
- name: Checkout
20+
uses: actions/checkout@v2
21+
22+
- name: Merge PR
23+
uses: LabKey/gitHubActions/merge-release@master
24+
with:
25+
target_branch: ${{ github.event.pull_request.base.ref }}
26+
merge_branch: ${{ github.event.pull_request.head.ref }}
27+
pr_number: ${{ github.event.pull_request.number }}
28+
github_token: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)