-
Notifications
You must be signed in to change notification settings - Fork 30
53 lines (42 loc) · 1.02 KB
/
ci.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
name: CI
on:
push:
branches:
- master
tags:
- 'v*.*.*'
pull_request:
branches:
- '**'
jobs:
check:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./packages/chain
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Setup Node.js
uses: actions/setup-node@v1
with:
node-version: '14'
# Restore the yarn cache
- uses: c-hive/gha-yarn-cache@v1
- name: Yarn install
run: yarn install
- name: Build
run: yarn hardhat compile
- name: Test
run: yarn hardhat test
- name: Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: |
artifacts/contracts/Curve.sol/Curve.json
artifacts/contracts/Eth_broker.sol/Eth_broker.json
artifacts/contracts/Token.sol/Token.json
env:
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}