Skip to content

Commit 109f759

Browse files
Merge pull request #10 from thomaseizinger/release/1.1.0
Release version 1.1.0
2 parents a78e166 + 15de157 commit 109f759

File tree

6 files changed

+68
-33
lines changed

6 files changed

+68
-33
lines changed

.github/workflows/draft-new-release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
run: git checkout -b release/${{ env.RELEASE_VERSION }}
2323

2424
- name: Update changelog
25-
uses: thomaseizinger/keep-a-changelog-new-release@master
25+
uses: thomaseizinger/keep-a-changelog-new-release@1.1.0
2626
with:
2727
version: ${{ env.RELEASE_VERSION }}
2828

@@ -44,7 +44,7 @@ jobs:
4444
run: git push origin release/${{ env.RELEASE_VERSION }}
4545

4646
- name: Create pull request
47-
uses: thomaseizinger/create-pull-request@v1
47+
uses: thomaseizinger/create-pull-request@1.0.0
4848
with:
4949
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5050
head: release/${{ env.RELEASE_VERSION }}
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
name: "Publish new release"
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- master
7+
types:
8+
- closed
9+
10+
jobs:
11+
release:
12+
name: Publish new release
13+
runs-on: ubuntu-latest
14+
if: github.event.pull_request.merged == true # only merged pull requests must trigger this job
15+
steps:
16+
- name: Extract version from branch name (for release branches)
17+
if: startsWith(github.event.pull_request.head.ref, 'release/')
18+
run: |
19+
BRANCH_NAME="${{ github.event.pull_request.head.ref }}"
20+
VERSION=${BRANCH_NAME#release/}
21+
22+
echo "::set-env name=RELEASE_VERSION::$VERSION"
23+
24+
- name: Extract version from branch name (for hotfix branches)
25+
if: startsWith(github.event.pull_request.head.ref, 'hotfix/')
26+
run: |
27+
BRANCH_NAME="${{ github.event.pull_request.head.ref }}"
28+
VERSION=${BRANCH_NAME#hotfix/}
29+
30+
echo "::set-env name=RELEASE_VERSION::$VERSION"
31+
32+
- name: Create Release
33+
uses: fleskesvor/create-release@feature/support-target-commitish
34+
env:
35+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
36+
with:
37+
commitish: ${{ github.event.pull_request.merge_commit_sha }}
38+
tag_name: ${{ env.RELEASE_VERSION }}
39+
release_name: ${{ env.RELEASE_VERSION }}
40+
41+
- name: Merge release into dev branch
42+
uses: thomaseizinger/[email protected]
43+
with:
44+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
45+
head: release/${{ env.RELEASE_VERSION }}
46+
base: dev
47+
title: Merge release ${{ env.RELEASE_VERSION }} into dev branch
48+
reviewers: ${{ github.event.pull_request.user.login }}
49+
50+
# if needed, you can checkout the latest master here, build artifacts and publish / deploy them somewhere

.github/workflows/release.yml

Lines changed: 0 additions & 28 deletions
This file was deleted.

.travis.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
language: node
2+
node_js: 12
23

34
branches:
45
only:
5-
- release/*
6+
- /^release\/.*$/

CHANGELOG.md

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,24 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10+
## [1.1.0] - 2020-02-17
11+
12+
### Added
13+
14+
- GitHub action to backport releases to dev branch
15+
16+
### Fixed
17+
18+
- Merge commit is used to tag release instead of last commit on release branch
19+
1020
## [1.0.0] - 2020-02-15
1121

1222
### Added
1323

1424
- Everything since the beginning!
1525

16-
[Unreleased]: https://github.com/thomaseizinger/github-action-gitflow-release-workflow/compare/1.0.0...HEAD
26+
[Unreleased]: https://github.com/thomaseizinger/github-action-gitflow-release-workflow/compare/1.1.0...HEAD
27+
28+
[1.1.0]: https://github.com/thomaseizinger/github-action-gitflow-release-workflow/compare/1.0.0...1.1.0
1729

1830
[1.0.0]: https://github.com/thomaseizinger/github-action-gitflow-release-workflow/compare/794c3ba521cae6b168def8bdbfe1aa6a2c285257...1.0.0

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "github-action-gitflow-release-workflow",
3-
"version": "1.0.0",
3+
"version": "1.1.0",
44
"main": "index.js",
55
"author": "Thomas Eizinger <[email protected]>",
66
"license": "MIT",

0 commit comments

Comments
 (0)