Skip to content

Commit d8f2fc9

Browse files
committed
ci: update release workflow
1 parent 1bc53d7 commit d8f2fc9

File tree

1 file changed

+29
-12
lines changed

1 file changed

+29
-12
lines changed

.github/workflows/release.yml

Lines changed: 29 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,33 @@
1-
# Reusable workflow for releases; to eject, you can replace this file with
2-
# https://github.com/ryansonshine/ryansonshine/blob/main/.github/workflows/release.yml
31
name: Release
42
on:
5-
push:
6-
branches:
7-
- main
3+
workflow_call:
4+
secrets:
5+
NPM_TOKEN:
6+
required: true
7+
88
jobs:
99
release:
10-
permissions:
11-
contents: write
12-
issues: write
13-
pull-requests: write
14-
uses: ryansonshine/ryansonshine/.github/workflows/release.yml@main
15-
secrets:
16-
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
10+
name: Release
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Checkout
14+
uses: actions/checkout@v3
15+
with:
16+
fetch-depth: 0
17+
- name: Setup Node.js
18+
uses: actions/setup-node@v3
19+
with:
20+
node-version: lts/*
21+
- name: Install dependencies
22+
run: npm ci
23+
- name: Build
24+
run: npm run build
25+
- name: Test
26+
run: npm test
27+
- name: Release
28+
env:
29+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
30+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
31+
run: npx semantic-release
32+
- name: Upload Code Coverage
33+
uses: codecov/codecov-action@v3.1.0

0 commit comments

Comments
 (0)