-
Notifications
You must be signed in to change notification settings - Fork 2
33 lines (33 loc) · 874 Bytes
/
build.yml
File metadata and controls
33 lines (33 loc) · 874 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
name: build
on:
release:
types: [created]
push:
branches:
- '**'
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '20.x'
registry-url: 'https://registry.npmjs.org'
cache: npm
- uses: microbit-foundation/npm-package-versioner-action@v1
- run: npm ci
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- run: npm run ci
- name: Upload GitHub packages artifact
uses: actions/upload-pages-artifact@v3
with:
path: ./storybook-static
- run: npm publish
if: github.event_name == 'release' && github.event.action == 'created'
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}