Skip to content

Commit

Permalink
fix: cache
Browse files Browse the repository at this point in the history
  • Loading branch information
alexghr committed Oct 11, 2024
1 parent 71c005a commit d887bbe
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 9 deletions.
4 changes: 3 additions & 1 deletion barretenberg/cpp/bootstrap_cache.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,7 @@ barretenberg-preset-release-world-state
# # clobber the existing build with the cached build
cp -r $TMP/barretenberg-preset-wasm/build build-wasm/
cp -r $TMP/barretenberg-preset-wasm-threads/build build-wasm-threads/
cp -r $TMP/barretenberg-preset-release/build build/

mkdir -p build
cp -r $TMP/barretenberg-preset-release/build/* build/
cp -r $TMP/barretenberg-preset-release-world-state/build/* build/
9 changes: 5 additions & 4 deletions barretenberg/ts/bootstrap_cache.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,12 @@ echo "
bb.js-esm
bb.js-cjs
bb.js-browser
" | xargs --max-procs 0 -I {} bash -c "$SCRIPTS_PATH/cache-download.sh {}-$HASH.tar.gz $TMP/{}"
" | xargs --max-procs 0 -I {} bash -c "$CACHE_SCRIPTS/cache-download.sh {}-$HASH.tar.gz $TMP/{}"

cp -r $TMP/bb.js-esm/dest dest
cp -r $TMP/bb.js-cjs/dest dest
cp -r $TMP/bb.js-browser/dest dest
mkdir -p dest
cp -r $TMP/bb.js-esm/dest/* dest/
cp -r $TMP/bb.js-cjs/dest/* dest/
cp -r $TMP/bb.js-browser/dest/* dest/

# Annoyingly we still need to install modules, so they can be found as part of module resolution when portalled.
yarn install
8 changes: 4 additions & 4 deletions noir-projects/bootstrap_cache.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ MOCK_CIRCUITS_HASH=$(AZTEC_CACHE_REBUILD_PATTERNS="../noir/.rebuild_patterns_nat
CONTRACTS_HASH=$(AZTEC_CACHE_REBUILD_PATTERNS="../noir/.rebuild_patterns_native ../avm-transpiler/.rebuild_patterns ../barretenberg/cpp/.rebuild_patterns noir-contracts/.rebuild_patterns" $SCRIPTS_PATH/compute-content-hash.sh)

echo "
noir-protocol-circuits
mock-protocol-circuits
noir-contracts
" | xargs --max-procs 0 -I {} bash -c "$SCRIPTS_PATH/cache-download.sh noir-projects-{}-$HASH.tar.gz {}"
noir-protocol-circuits $PROTOCOL_CIRCUITS_HASH
mock-protocol-circuits $MOCK_CIRCUITS_HASH
noir-contracts $CONTRACTS_HASH
" | xargs --max-procs 0 --max-args 2 bash -c "$SCRIPTS_PATH/cache-download.sh noir-projects-\$0-\$1.tar.gz \$0"

yarn

0 comments on commit d887bbe

Please sign in to comment.