-
Notifications
You must be signed in to change notification settings - Fork 11
49 lines (42 loc) · 1.06 KB
/
cicd.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
name: Cicd
on:
push:
branches: ['master']
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Checkout submodules
run: |
git submodule update --init --recursive
git submodule update --remote --merge
- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version: 18.x
- name: Build
run: |
yarn
yarn build
- name: E2E tests
run: |
yarn hardhat node > /dev/null &
sleep 5
yarn testE2e
- name: Artifacts
uses: actions/upload-artifact@v2
with:
name: result
path: |
lib
package.json
- name: prepare publish
run: echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_AUTH_TOKEN }}" > ~/.npmrc
- name: remove .gitignore for publish
run: rm .gitignore
- name: publish
run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}