Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Anton Baliasnikov
committed
Oct 21, 2022
1 parent
7d86906
commit 80281ec
Showing
2 changed files
with
52 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
name: Release | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
release-component: | ||
description: "Release component" | ||
required: true | ||
default: "mercury/prism-mediator" | ||
release-branch: | ||
description: "Branch to release from" | ||
required: false | ||
default: "main" | ||
|
||
jobs: | ||
release: | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.ATALA_GITHUB_TOKEN }} | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
ref: ${{ github.event.inputs.release-branch }} | ||
fetch-depth: 0 | ||
- name: Setup Java and Scala | ||
uses: olafurpg/setup-scala@v13 | ||
with: | ||
java-version: openjdk@1.11 | ||
- name: Setup Node.js | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 'lts/*' | ||
- uses: crazy-max/ghaction-import-gpg@v3 | ||
id: import_gpg | ||
with: | ||
gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }} | ||
git-user-signingkey: true | ||
git-commit-gpgsign: true | ||
- name: Release | ||
run: | | ||
# Set required environment variables for semantic-release-git | ||
export GIT_AUTHOR_EMAIL="${{ steps.import_gpg.outputs.email }}" | ||
export GIT_COMMITTER_EMAIL="${GIT_AUTHOR_EMAIL}" | ||
export GIT_AUTHOR_NAME="${{ steps.import_gpg.outputs.name }}" | ||
export GIT_COMMITTER_NAME="${GIT_AUTHOR_NAME}" | ||
# Install and run release process | ||
cd ${{ github.event.inputs.release-component }} | ||
npm install | ||
npx semantic-release -e semantic-release-monorepo |