-
Notifications
You must be signed in to change notification settings - Fork 12
48 lines (44 loc) · 1.24 KB
/
deploy-BETA.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
40
41
42
43
44
45
46
47
48
---
#
# Documentation:
# https://help.github.com/en/articles/workflow-syntax-for-github-actions
#
#######################################
# Start the job on all push to master #
#######################################
name: "Build & Deploy - BETA"
on:
push:
branches:
- "main"
- "master"
permissions: read-all
concurrency:
group: ${{ github.ref_name }}-${{ github.workflow }}
cancel-in-progress: true
###############
# Set the Job #
###############
jobs:
deploy:
name: Deploy beta
runs-on: ubuntu-latest
permissions: read-all
environment:
name: beta
steps:
- uses: actions/checkout@v3
# Setup .npmrc file to publish to npm
- uses: actions/setup-node@v3
with:
node-version: 18
registry-url: "https://registry.npmjs.org"
always-auth: true
# Defaults to the user or organization that owns the workflow file
scope: "rubenhalman"
- run: yarn
- run: yarn config set version-git-tag false && tsc -b
- run: BETAID=$(date '+%Y%m%d%H%M') && yarn version --prepatch --preid="beta$BETAID"
- run: yarn config set network-timeout 300000 && yarn publish --tag beta
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}