-
-
Notifications
You must be signed in to change notification settings - Fork 6
39 lines (36 loc) · 1.07 KB
/
deploy-RELEASE.yml
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
34
35
36
37
38
39
---
#
# Documentation:
# https://help.github.com/en/articles/workflow-syntax-for-github-actions
#
#######################################
# Start the job on all push to master #
#######################################
name: "Build & Deploy - RELEASE"
on:
release:
# Want to run the automation when a release is created
types: ["created"]
permissions: read-all
###############
# Set the Job #
###############
jobs:
deploy:
runs-on: ubuntu-latest
permissions: read-all
environment:
name: release
steps:
- uses: actions/checkout@v4
# Setup .npmrc file to publish to npm
- uses: actions/setup-node@v4
with:
node-version: 18
registry-url: "https://registry.npmjs.org"
# Defaults to the user or organization that owns the workflow file
scope: "nvuillam"
- run: yarn
- run: yarn config set network-timeout 300000 && yarn publish || echo "Unable to publish package version. Or published in background because of NPM bug ?"
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}