-
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #42 from nitrictech/feature/release-workflow
Release workflow
- Loading branch information
Showing
31 changed files
with
191 additions
and
152 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,8 +11,6 @@ jobs: | |
- name: Checkout | ||
uses: actions/[email protected] | ||
with: | ||
token: ${{secrets.SUBMOD_PAT}} | ||
submodules: recursive | ||
fetch-depth: 0 # needed to retrieve most recent tag | ||
- name: Set up Python 3.8 | ||
uses: actions/setup-python@v2 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
name: Release Candidate | ||
on: | ||
pull_request: | ||
types: [closed] | ||
branches: | ||
- 'develop' | ||
|
||
jobs: | ||
# Bump the SDK version | ||
version_bump: | ||
if: github.event.pull_request.merged == true | ||
name: Bump Version and Create Release | ||
runs-on: ubuntu-latest | ||
outputs: | ||
version_id: ${{ steps.tag_version.outputs.new_tag }} | ||
upload_url: ${{ steps.create_release.outputs.upload_url }} | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
- name: Bump version and push tag | ||
id: tag_version | ||
uses: mathieudutour/[email protected] | ||
with: | ||
# Don't commit tag | ||
# this will be done as part of the release | ||
dry_run: true | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
release_branches: main,develop | ||
|
||
- name: Calculate RC number | ||
id: vars | ||
run: echo "::set-output name=rc_num::$(git rev-list --merges --count origin/develop...origin/main)" | ||
|
||
- name: Create a GitHub release | ||
id: create_release | ||
uses: actions/create-release@v1 | ||
env: | ||
# Use NITRIC_BOT_TOKEN here to | ||
# trigger release 'published' workflows | ||
GITHUB_TOKEN: ${{ secrets.NITRIC_BOT_TOKEN }} | ||
with: | ||
prerelease: true | ||
tag_name: ${{ steps.tag_version.outputs.new_tag }}-rc.${{ steps.vars.outputs.rc_num }} | ||
release_name: Release ${{ steps.tag_version.outputs.new_tag }}-rc.${{ steps.vars.outputs.rc_num }} | ||
body: ${{ steps.tag_version.outputs.changelog }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
name: Production Release | ||
on: | ||
pull_request: | ||
types: [closed] | ||
branches: | ||
- 'main' | ||
jobs: | ||
# Bump the SDK version | ||
version_bump: | ||
if: github.event.pull_request.merged == true | ||
name: Bump Version and Create Release | ||
runs-on: ubuntu-latest | ||
outputs: | ||
version_id: ${{ steps.tag_version.outputs.new_tag }} | ||
upload_url: ${{ steps.create_release.outputs.upload_url }} | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
- name: Bump version and push tag | ||
id: tag_version | ||
uses: mathieudutour/[email protected] | ||
with: | ||
# Use GITHUB_TOKEN here to prevent further workflows | ||
# generated on 'tag' action | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
- name: Create a GitHub release | ||
id: create_release | ||
uses: actions/create-release@v1 | ||
env: | ||
# Use NITRIC_BOT_TOKEN here to | ||
# trigger release 'published' workflows | ||
GITHUB_TOKEN: ${{ secrets.NITRIC_BOT_TOKEN }} | ||
with: | ||
tag_name: ${{ steps.tag_version.outputs.new_tag }} | ||
release_name: Release ${{ steps.tag_version.outputs.new_tag }} | ||
body: ${{ steps.tag_version.outputs.changelog }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Submodule contracts
deleted from
43e281
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.