-
Notifications
You must be signed in to change notification settings - Fork 9
63 lines (56 loc) · 1.7 KB
/
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: Release
on:
push:
branches:
- main
- beta
jobs:
Release:
if: "!contains(github.event.head_commit.message, 'SKIP CI')"
runs-on: ubuntu-latest
steps:
# Setup the git repo & Node environemnt.
#
- name: Checkout branch (${{ github.ref }})
uses: actions/checkout@v4
with:
persist-credentials: false # install breaks with persistant creds!
- name: Setup node
uses: actions/setup-node@v4
with:
node-version: 20
- name: Install dependencies
run: |
npm ci
npm run build --if-present
env:
PUPPETEER_SKIP_DOWNLOAD: true
# Build, version, and tag a new release.
#
- name: Publish release
run: npm run release # configured in .releaserc
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }} # auth push to remote repo
NPM_TOKEN: ${{ secrets.NPM_TOKEN || secrets.GH_TOKEN }} # auth publish to registry
# Push release changes to the remote.
#
- name: Push to remote
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: ${{ github.ref }}
# Merge @latest release back to @next.
#
#- name: Sync to next
# if: "github.ref == 'refs/heads/main'"
# uses: ad-m/github-push-action@master
# with:
# github_token: ${{ secrets.GITHUB_TOKEN }}
# branch: ${{ github.ref }}
# continue-on-error: true
# Sync docs to rdmd.readme.io
#
#- name: Sync docs to rdmd.readme.io
# uses: readmeio/rdme@v8
# with:
# rdme: docs ./docs --key=${{ secrets.RDME_KEY }} --version=2