diff --git a/bootstrap.sh b/bootstrap.sh index 43b0c217ffc..62b93deb023 100755 --- a/bootstrap.sh +++ b/bootstrap.sh @@ -35,38 +35,4 @@ if [ ! -f ~/.nvm/nvm.sh ]; then fi circuits/cpp/bootstrap.sh - -if [ "$(uname)" = "Darwin" ]; then - # works around https://github.com/AztecProtocol/aztec3-packages/issues/158 - echo "Note: not sourcing nvm on Mac, see github #158" -else - \. ~/.nvm/nvm.sh -fi -nvm install - -cd yarn-project -yarn install --immutable - -# Build the necessary dependencies for noir contracts typegen. -for DIR in foundation noir-compiler circuits.js; do - echo "Building $DIR..." - cd $DIR - yarn build - cd .. -done - -# Run remake bindings before building noir contracts or l1 contracts as they depend on files created by it. -yarn --cwd circuits.js remake-bindings -yarn --cwd circuits.js remake-constants - -(cd noir-contracts && ./bootstrap.sh) -(cd .. && l1-contracts/bootstrap.sh) - -# Until we push .yarn/cache, we still need to install. -yarn -# We do not need to build individual packages, yarn build will build the root tsconfig.json -yarn build -cd .. - -echo -echo "Success! You could now run e.g.: ./scripts/tmux-splits e2e_deploy_contract" +yarn-project/bootstrap.sh diff --git a/circuits/cpp/bootstrap.sh b/circuits/cpp/bootstrap.sh index a242d6dc0e3..74347c5412b 100755 --- a/circuits/cpp/bootstrap.sh +++ b/circuits/cpp/bootstrap.sh @@ -5,6 +5,7 @@ set -eu export WASI_VERSION=20 +# Navigate to script folder cd "$(dirname "$0")" # Update the submodule diff --git a/yarn-project/bootstrap.sh b/yarn-project/bootstrap.sh new file mode 100755 index 00000000000..39036119ed7 --- /dev/null +++ b/yarn-project/bootstrap.sh @@ -0,0 +1,38 @@ +#!/bin/bash +set -eu + +# Navigate to script folder +cd "$(dirname "$0")" + +if [ "$(uname)" = "Darwin" ]; then + # works around https://github.com/AztecProtocol/aztec3-packages/issues/158 + echo "Note: not sourcing nvm on Mac, see github #158" +else + \. ~/.nvm/nvm.sh +fi +nvm install + +yarn install --immutable + +# Build the necessary dependencies for noir contracts typegen. +for DIR in foundation noir-compiler circuits.js; do + echo "Building $DIR..." + cd $DIR + yarn build + cd .. +done + +# Run remake bindings before building noir contracts or l1 contracts as they depend on files created by it. +yarn --cwd circuits.js remake-bindings +yarn --cwd circuits.js remake-constants + +(cd noir-contracts && ./bootstrap.sh) +(cd .. && l1-contracts/bootstrap.sh) + +# Until we push .yarn/cache, we still need to install. +yarn +# We do not need to build individual packages, yarn build will build the root tsconfig.json +yarn build + +echo +echo "Success! You can now e.g. run anvil and end-to-end tests"