Skip to content

Commit 0dc2bf1

Browse files
authored
chore(gh-actions): Fix release workflow (#55)
1 parent ee0e538 commit 0dc2bf1

File tree

3 files changed

+24
-37
lines changed

3 files changed

+24
-37
lines changed

.github/workflows/build.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ concurrency:
77
group: build-${{ github.ref_name }}
88
cancel-in-progress: true
99

10+
permissions:
11+
contents: write
12+
id-token: write
13+
issues: write
14+
1015
jobs:
1116
build:
1217
runs-on: ubuntu-latest
@@ -27,3 +32,21 @@ jobs:
2732
- run: yarn compile
2833
- run: yarn lint
2934
- run: yarn test --forbid-only
35+
36+
deploy:
37+
runs-on: ubuntu-latest
38+
needs: [build]
39+
if: github.ref_name == 'release'
40+
41+
steps:
42+
- uses: actions/checkout@v3
43+
- uses: actions/setup-node@v3
44+
with:
45+
node-version-file: '.nvmrc'
46+
cache: yarn
47+
- run: yarn install --immutable
48+
- run: yarn build
49+
- run: yarn semantic-release
50+
env:
51+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
52+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

.github/workflows/pages.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: Pages
33

44
on:
55
workflow_run:
6-
workflows: [Release]
6+
workflows: [Build]
77
branches: [release]
88
types:
99
- completed

.github/workflows/release.yml

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

0 commit comments

Comments
 (0)