@@ -3,17 +3,35 @@ set -euo pipefail
33
44NOIR_VERSION=" 1.0.0-beta.3"
55BB_VERSION=" v0.82.2"
6- export PATH=" $HOME /.nargo/bin:$HOME /.bb/bin:$PATH "
76
8- command -v nargo > /dev/null || {
9- curl -L https://raw.githubusercontent.com/noir-lang/noirup/main/install \
10- | NOIR_VERSION=" $NOIR_VERSION " bash
11- }
12- command -v bb > /dev/null || {
13- curl -L https://raw.githubusercontent.com/AztecProtocol/aztec-packages/master/barretenberg/bbup/install \
14- | BB_VERSION=" $BB_VERSION " bash
7+ add_to_ci_path () {
8+ if [ -n " ${GITHUB_PATH:- } " ]; then
9+ echo " $1 " >> " $GITHUB_PATH "
10+ fi
1511}
1612
13+ # install noirup
14+ if ! command -v noirup > /dev/null 2>&1 ; then
15+ curl -L https://raw.githubusercontent.com/noir-lang/noirup/main/install | bash
16+ add_to_ci_path " $HOME /.nargo/bin"
17+ export PATH=" $HOME /.nargo/bin:$PATH "
18+ fi
19+
20+ # install nargo
21+ command -v nargo > /dev/null 2>&1 || NOIR_VERSION=" $NOIR_VERSION " noirup
22+
23+ # install bbup
24+ if ! command -v bbup > /dev/null 2>&1 ; then
25+ curl -L https://raw.githubusercontent.com/AztecProtocol/aztec-packages/master/barretenberg/bbup/install | bash
26+ add_to_ci_path " $HOME /.bb/bin"
27+ export PATH=" $HOME /.bb/bin:$PATH "
28+ fi
29+
30+ # install bb
31+ command -v bb > /dev/null 2>&1 || \
32+ BB_VERSION=" $BB_VERSION " bbup install " $BB_VERSION " --skip-compat-check
33+
34+ # build every circuit ─
1735for dir in circuits/* ; do
1836 [ -d " $dir " ] || continue
1937 name=$( basename " $dir " )
0 commit comments