-
Notifications
You must be signed in to change notification settings - Fork 0
33 lines (33 loc) · 1.13 KB
/
release.yaml
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: Publish Package
on:
release:
types: [created]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
# Setup .npmrc file to publish to npm
- uses: actions/setup-node@v3
with:
node-version: 22
# check if caches can be added
# cache: 'yarn'
# cache-dependency-path: 'yarn.lock'
registry-url: 'https://registry.npmjs.org'
# Defaults to the user or organization that owns the workflow file
scope: '@sitegeist'
# check if cache really needs cleaning
# - run: yarn cache clean --all
- run: yarn set version 4.5.0 # see if can be ommited
- run: |
yarn config set npmScopes.sitegeist.npmRegistryServer "https://registry.npmjs.org"
yarn config set npmScopes.sitegeist.npmAlwaysAuth true
yarn config set npmScopes.sitegeist.npmAuthToken $NODE_AUTH_TOKEN
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- run: yarn install
- run: yarn build
- run: yarn npm publish --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}