Skip to content

Commit 4ac0870

Browse files
authored
fix(docs): netlify autogenerate aztec-nr installs correct version (#21043)
this was breaking docs builds
2 parents 0bee997 + 935481e commit 4ac0870

1 file changed

Lines changed: 12 additions & 2 deletions

File tree

docs/scripts/netlify-preview-build.sh

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,20 @@ DOCS_ROOT="$(cd "$SCRIPT_DIR/.." && pwd)"
88

99
echo "=== Installing noirup and nargo ==="
1010
export PATH="$HOME/.nargo/bin:$PATH"
11+
12+
# Ensure noir submodule is available for version detection
13+
REPO_ROOT="$DOCS_ROOT/.."
14+
if [ ! -f "$REPO_ROOT/noir/noir-repo/.git" ] && [ ! -d "$REPO_ROOT/noir/noir-repo/.git" ]; then
15+
git -C "$REPO_ROOT" submodule update --init --depth 1 noir/noir-repo
16+
fi
17+
18+
# Use the pinned noir version from the submodule (falls back to nightly)
19+
NOIR_TAG=$(git -C "$REPO_ROOT/noir/noir-repo" describe --tags --exact-match 2>/dev/null || echo "nightly")
20+
echo "Using noir version: $NOIR_TAG"
21+
1122
# Install noirup (ignore shell detection failure - binary still gets installed)
1223
curl -L https://raw.githubusercontent.com/noir-lang/noirup/main/install | bash || true
13-
# Install nargo nightly
14-
noirup -v nightly
24+
noirup -v "$NOIR_TAG"
1525

1626
echo "=== Verifying nargo installation ==="
1727
nargo --version

0 commit comments

Comments
 (0)