-
Notifications
You must be signed in to change notification settings - Fork 38
/
action.yml
53 lines (52 loc) · 1.63 KB
/
action.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
name: Build Contract Artifacts
description: Common builder for test contracts for automated tests
inputs:
ref:
required: false
description: The chainlink-solana ref to use
runs:
using: composite
steps:
- name: Install latest Git version (>= 2.18.0) for actions/checkout
shell: bash
run: |
apt-get update
apt-get install software-properties-common -y
add-apt-repository ppa:git-core/ppa
apt update
apt install git -y
git config --global --add safe.directory "$GITHUB_WORKSPACE"
- uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8 # v3.1.0
with:
repository: smartcontractkit/chainlink-solana
ref: ${{ inputs.ref }}
- name: Setup go
uses: actions/setup-go@v3
with:
go-version-file: "go.mod"
check-latest: true
- name: yarn install
shell: bash
run: yarn install --frozen-lockfile
- name: Generate build artifacts for go bindings check
shell: bash
run: anchor build
working-directory: contracts
- name: Check generated go bindings are up to date
shell: bash
run: |
go install github.com/gagliardetto/anchor-go@v0.2.3
./scripts/anchor-go-gen.sh
git diff --stat --exit-code
- name: Generate program_ids
shell: bash
run: ./scripts/programs-keys-gen.sh
- name: Generate build artifacts with custom program_ids
shell: bash
run: anchor build
working-directory: contracts
- name: Upload Artifacts
uses: actions/upload-artifact@master
with:
name: artifacts
path: contracts/target/deploy