-
Notifications
You must be signed in to change notification settings - Fork 42
60 lines (47 loc) · 1.53 KB
/
patchrelease.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
name: patchrelease
on:
push:
branches:
- patchrelease
jobs:
build-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Read .nvmrc
run: echo "NODE_VERSION=$(cat .nvmrc)" >> $GITHUB_OUTPUT
id: nvmrc
- name: setup node ${{ steps.nvmrc.outputs.NODE_VERSION }}
uses: actions/setup-node@v4
with:
node-version: '${{ steps.nvmrc.outputs.NODE_VERSION }}'
registry-url: 'https://registry.npmjs.org'
- name: install dependencies
run: yarn
- name: build design tokens package
run: yarn build
working-directory: ./packages/design-tokens
- name: build core package
run: yarn build
working-directory: ./packages/core
- name: build react package
run: yarn build
working-directory: ./packages/react
- name: build hds-js package
run: yarn build:hds-js
working-directory: ./packages/react
- name: build standalone hds-js package
run: yarn build:hds-js-standalone
working-directory: ./packages/react
- name: release npm packages
run: yarn release --dist-tag patch
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: delete the patchrelease branch
run: |
git config --global user.email "[email protected]"
git config --global user.name "Github Actions"
git push origin --delete patchrelease
- name: End
run: echo "Done!"