-
Notifications
You must be signed in to change notification settings - Fork 0
57 lines (48 loc) · 1.57 KB
/
fhevm-core-contracts-publish.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
name: Publish fhEVM Solidity core contracts
on:
workflow_dispatch:
inputs:
release:
description: "Set to true for release tagging"
required: false
default: false
jobs:
publish:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./contracts
permissions:
contents: read
id-token: write
packages: write
steps:
- name: Check out repository
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
- name: Set up Node.js
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
with:
node-version: 20.x
- name: Prepare environment file
run: cp .env.example.deployment .env
- name: Install dependencies
run: npm ci --include=optional
- name: Compile contracts
run: npm run compile
- name: Compile decryption oracle
run: npm run compile:decryptionOracle
- name: Publish prerelease to npm
if: ${{ inputs.release != 'true' }}
uses: JS-DevTools/npm-publish@19c28f1ef146469e409470805ea4279d47c3d35c # v3.1.1
with:
package: ./contracts/package.json
tag: prerelease
token: ${{ secrets.NPM_TOKEN }}
provenance: true
- name: Publish release to npm
if: ${{ inputs.release == 'true' }}
uses: JS-DevTools/npm-publish@19c28f1ef146469e409470805ea4279d47c3d35c # v3.1.1
with:
package: ./contracts/package.json
token: ${{ secrets.NPM_TOKEN }}
provenance: true