Skip to content

Commit

Permalink
Add release workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
marcofranssen committed Jul 25, 2022
1 parent 3fa2929 commit 9b123d8
Show file tree
Hide file tree
Showing 2 changed files with 63 additions and 0 deletions.
51 changes: 51 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: Release
on:
push:
tags:
- v*

concurrency:
group: release-${{ github.ref }}
cancel-in-progress: true

jobs:
release:
name: Release
runs-on: ubuntu-22.04

permissions:
contents: write

steps:
- uses: actions/[email protected]

- name: Setup Node
uses: actions/[email protected]
with:
node-version: '16'

- name: Setup yarn
run: npm install -g yarn

- name: Install dependencies
run: yarn install

- name: Check dist updated
run: |
yarn build
git diff --quiet -- dist || {
echo "::error::The ./dist is outdated, run 'yarn build' and commit"
exit 1
}
- uses: ncipollo/[email protected]
id: release
with:
draft: ${{ contains(github.ref, '-draft') }}
prerelease: ${{ contains(github.ref, '-rc') || contains(github.ref, '-alpha') || contains(github.ref, '-beta') }}
generateReleaseNotes: true
allowUpdates: true
token: ${{ secrets.GITHUB_TOKEN }}

- name: Workflow notices
run: echo "::notice title=Release::${{ steps.release.outputs.html_url }}"
12 changes: 12 additions & 0 deletions .github/workflows/test-iamlive-action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,20 @@ jobs:
- name: Check out code
uses: actions/[email protected]

- name: Setup Node
uses: actions/[email protected]
with:
node-version: '16'

- name: Setup yarn
run: npm install -g yarn

- name: Install dependencies
run: yarn install

- name: Check diff is up to date
run: |
yarn build
git diff --quiet -- dist || {
echo "::error::The ./dist is outdated, run 'yarn build' and commit"
exit 1
Expand Down

0 comments on commit 9b123d8

Please sign in to comment.