Skip to content

Commit e7d85ff

Browse files
author
AztecBot
committed
Merge branch 'next' into merge-train/avm
2 parents 731b626 + be5f6ab commit e7d85ff

File tree

14 files changed

+696
-42
lines changed

14 files changed

+696
-42
lines changed

.github/workflows/nightly-docs-release.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,14 +130,15 @@ jobs:
130130
- name: Create Aztec nightly docs version (Developer docs only)
131131
working-directory: ./docs
132132
run: |
133-
# Set the commit tag for version macros
133+
# Set the commit tag and release type for version macros
134134
export COMMIT_TAG=${{ env.NIGHTLY_TAG }}
135+
export RELEASE_TYPE=nightly
135136
136137
# Install dependencies
137138
yarn install
138139
139140
# Build docs to ensure everything works
140-
COMMIT_TAG=${{ env.NIGHTLY_TAG }} yarn build
141+
COMMIT_TAG=${{ env.NIGHTLY_TAG }} RELEASE_TYPE=nightly yarn build
141142
142143
# Create the versioned docs for Developer docs only
143144
# Network docs have separate versions for testnet/ignition releases

docs/CLAUDE.md

Lines changed: 51 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,8 @@ The documentation uses a **preprocessing system** that:
2727

2828
- Pulls code from source files using `#include_code` macros
2929
- Generates auto-documentation from TypeScript/JavaScript sources
30-
- Processes macros like `#include_aztec_version` and `#include_testnet_version`
30+
- Processes version macros (`#release_version`, `#release_network`, `#include_aztec_version`, etc.)
31+
- Processes conditional content blocks (`#if`/`#elif`/`#else`/`#endif`)
3132
- Outputs to `processed-docs/` folder (used only in production builds)
3233

3334
For development:
@@ -36,6 +37,52 @@ For development:
3637
- `yarn start` - Runs preprocessing once at startup and serves from source directories
3738
- **Important**: Hot reloading is NOT available - you must restart the dev server to see changes
3839

40+
### Preprocessing Environment Variables
41+
42+
The preprocessing system uses these environment variables:
43+
44+
| Variable | Description | Default |
45+
|----------|-------------|---------|
46+
| `RELEASE_TYPE` | Release type: `nightly`, `devnet`, `testnet`, `mainnet`, `ignition` | `nightly` |
47+
| `NIGHTLY_TAG` | Version for nightly builds (falls back to `COMMIT_TAG`) | `0.0.0-nightly.0` |
48+
| `DEVNET_TAG` | Version for devnet builds | `3.0.0-devnet.5` |
49+
| `TESTNET_TAG` | Version for testnet builds | `2.1.9` |
50+
| `MAINNET_TAG` | Version for mainnet/ignition builds | `2.1.9` |
51+
| `COMMIT_TAG` | Legacy variable, used as fallback for `NIGHTLY_TAG` | `next` |
52+
53+
### Preprocessing Macros
54+
55+
**Release-type-aware macros:**
56+
- `#release_version` - Resolves to the version for the current `RELEASE_TYPE`:
57+
- `nightly``NIGHTLY_TAG`, `devnet``DEVNET_TAG`, `testnet``TESTNET_TAG`, `mainnet`/`ignition``MAINNET_TAG`
58+
- `#release_network` - Resolves to the network name for CLI `--network` flag:
59+
- `nightly``local-network`, `devnet``devnet`, `testnet``testnet`, `mainnet`/`ignition``mainnet`
60+
61+
**Legacy macros:**
62+
- `#include_aztec_version` - Uses `COMMIT_TAG`
63+
- `#include_devnet_version`, `#include_testnet_version`, `#include_mainnet_version` - Version-specific macros
64+
65+
### Conditional Content
66+
67+
Use conditional blocks to show content only for specific release types:
68+
69+
```markdown
70+
#if(devnet)
71+
Content for devnet docs
72+
#elif(testnet)
73+
Content for testnet docs
74+
#else
75+
Default content
76+
#endif
77+
```
78+
79+
**Supported conditions** (matching `RELEASE_TYPE` values): `nightly`, `devnet`, `testnet`, `mainnet`, `ignition`
80+
81+
**Notes:**
82+
- Conditional blocks are processed before version macro substitution (so you can use version macros inside conditionals)
83+
- Nested conditionals are not supported
84+
- The `#else` block is optional
85+
3986
## Documentation Architecture
4087

4188
### Key Directories
@@ -67,7 +114,7 @@ Uses Docusaurus multi-instance versioning with separate version tracks:
67114
- **Developer docs**: Versions in `developer_versions.json`, stored in `developer_versioned_docs/`
68115
- **Network docs**: Versions in `network_versions.json`, stored in `network_versioned_docs/`
69116
- Each docs instance has its own version dropdown in the navbar
70-
- Macros (`#include_code`, `#include_aztec_version`, etc.) only work in source folders, not in versioned copies
117+
- Preprocessing macros (`#include_code`, `#release_version`, conditionals, etc.) only work in source folders, not in versioned copies
71118
- Create new versions with: `yarn docusaurus docs:version:<instance-id> <version>`
72119

73120
## Documentation Review Standards
@@ -255,5 +302,5 @@ Approved external documentation sources:
255302
- Flag any content that might need subject matter expert review
256303
- Suggest improvements even if they go beyond pure editing
257304

258-
Last updated: 2025-15-08
259-
Version: 1.1
305+
Last updated: 2025-12-24
306+
Version: 1.2

docs/README.md

Lines changed: 93 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,13 +51,15 @@ The way docs builds work is the following:
5151
- [The main CI workflow](../.github/workflows/ci3.yml) runs on pull requests and builds the dependencies and the docs, giving you a preview to check that everything is correct. You can also trigger docs CI specifically with the `ci-docs` label on a PR.
5252
- [The nightly docs workflow](../.github/workflows/nightly-docs-release.yml) runs daily to create versioned documentation for nightly releases, automatically cutting a new version of the docs for the latest nightly tag
5353

54-
The `#include_aztec_version` and `#include_code` macros look for the version tag in an environment variable `COMMIT_TAG`, so you can build the docs specifying a version with the following command (e.g. for v3.0.0-devnet.5):
54+
The preprocessing macros use environment variables to determine version numbers. For nightly builds, set `NIGHTLY_TAG` (or `COMMIT_TAG` for backwards compatibility):
5555

5656
```bash
57-
COMMIT_TAG=v3.0.0-devnet.5 yarn build
57+
NIGHTLY_TAG=v3.0.0-nightly.20251218 yarn build
5858
```
5959

60-
You can add the aztec version to a docs page without the `v` prefix with `#include_version_without_prefix`, so COMMIT_TAG `v3.0.0-devnet.5` will render as `3.0.0-devnet.5`.
60+
For other release types, use `RELEASE_TYPE` with the corresponding tag variable (see [RELEASE_TYPE Environment Variable](#release_type-environment-variable) for details).
61+
62+
The legacy `#include_aztec_version` macro uses `COMMIT_TAG`, while `#include_version_without_prefix` strips the `v` prefix (e.g., `v3.0.0-devnet.5` renders as `3.0.0-devnet.5`).
6163

6264
### How do I change the versions that show in the website
6365

@@ -318,6 +320,94 @@ This value may be different from the `#include_aztec_version` macro, since the t
318320
This macro will be replaced inline with the provided devnet version. This value is sourced from the `DEVNET_TAG` environment variable when running `yarn build` (e.g. `DEVNET_TAG=3.0.0-devnet.4 yarn build`). If not specified, it defaults to `3.0.0-devnet.4`.
319321
This value may be different from both `#include_aztec_version` and `#include_testnet_version` macros, since the devnet version represents a separate development network release.
320322
323+
### `#include_mainnet_version`
324+
325+
This macro will be replaced inline with the provided mainnet version. This value is sourced from the `MAINNET_TAG` environment variable when running `yarn build` (e.g. `MAINNET_TAG=2.1.9 yarn build`). If not specified, it defaults to `2.1.9`.
326+
This value is used for mainnet and ignition releases.
327+
328+
### `#release_version`
329+
330+
This macro is release-type-aware and automatically resolves to the appropriate version based on the `RELEASE_TYPE` environment variable:
331+
332+
| RELEASE_TYPE | Resolves to | Example |
333+
|--------------|-------------|---------|
334+
| nightly | `NIGHTLY_TAG` (falls back to `COMMIT_TAG`) | `3.0.0-nightly.20251218` |
335+
| devnet | `DEVNET_TAG` | `3.0.0-devnet.5` |
336+
| testnet | `TESTNET_TAG` | `2.1.9` |
337+
| mainnet | `MAINNET_TAG` | `2.1.9` |
338+
| ignition | `MAINNET_TAG` | `2.1.9` |
339+
340+
Usage: `aztecprotocol/aztec:#release_version`
341+
342+
### `#release_network`
343+
344+
This macro resolves to the network name for use with the `--network` CLI flag:
345+
346+
| RELEASE_TYPE | Resolves to |
347+
|--------------|-------------|
348+
| nightly | `local-network` |
349+
| devnet | `devnet` |
350+
| testnet | `testnet` |
351+
| mainnet | `mainnet` |
352+
| ignition | `mainnet` |
353+
354+
Usage: `--network #release_network`
355+
356+
### `RELEASE_TYPE` Environment Variable
357+
358+
The `RELEASE_TYPE` environment variable controls which release type the documentation is being built for. Valid values are:
359+
360+
- `nightly` (default) - For nightly developer docs releases
361+
- `devnet` - For devnet releases
362+
- `testnet` - For testnet releases
363+
- `mainnet` - For mainnet releases
364+
- `ignition` - For ignition releases (treated as mainnet)
365+
366+
Example build commands:
367+
```bash
368+
# Build for nightly (default)
369+
NIGHTLY_TAG=v3.0.0-nightly.20251218 yarn build
370+
371+
# Build for devnet
372+
RELEASE_TYPE=devnet DEVNET_TAG=3.0.0-devnet.5 yarn build
373+
374+
# Build for testnet
375+
RELEASE_TYPE=testnet TESTNET_TAG=2.1.9 yarn build
376+
377+
# Build for ignition/mainnet
378+
RELEASE_TYPE=ignition MAINNET_TAG=2.1.9 yarn build
379+
```
380+
381+
### Conditional Content
382+
383+
You can include content that only appears for specific release types using conditional blocks:
384+
385+
```markdown
386+
#if(nightly)
387+
Content that only appears in nightly docs
388+
#elif(devnet)
389+
Content that only appears in devnet docs
390+
#elif(testnet)
391+
Content that only appears in testnet docs
392+
#elif(mainnet)
393+
Content that only appears in mainnet/ignition docs
394+
#else
395+
Default content if no condition matches
396+
#endif
397+
```
398+
399+
**Supported conditions** (matching `RELEASE_TYPE` values):
400+
- `nightly` - True when `RELEASE_TYPE=nightly`
401+
- `devnet` - True when `RELEASE_TYPE=devnet`
402+
- `testnet` - True when `RELEASE_TYPE=testnet`
403+
- `mainnet` - True when `RELEASE_TYPE=mainnet` or `RELEASE_TYPE=ignition`
404+
- `ignition` - Alias for `mainnet`
405+
406+
**Notes:**
407+
- Conditional blocks are processed before version macro substitution, so you can use version macros inside conditionals
408+
- Nested conditionals are not supported
409+
- The `else` block is optional
410+
321411
## Viewing (outdated) protocol specs
322412

323413
The protocol specs pages are outdated, but it may still be useful to view them in some cases.

docs/docs-network/operation/monitoring_example_troubleshooting.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ Here's a complete example with all monitoring components integrated with your Az
1212
services:
1313
# Your Aztec node (example for full node)
1414
aztec-node:
15-
image: "aztecprotocol/aztec:2.1.9"
15+
image: "aztecprotocol/aztec:#release_version"
1616
container_name: "aztec-node"
1717
ports:
1818
- ${AZTEC_PORT}:${AZTEC_PORT}
@@ -36,7 +36,7 @@ services:
3636
start
3737
--node
3838
--archiver
39-
--network testnet
39+
--network #release_network
4040
networks:
4141
- aztec
4242
restart: always

docs/docs-network/prerequisites.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ bash -i <(curl -s https://install.aztec.network)
6363
Install the correct version for the current network:
6464

6565
```bash
66-
aztec-up #include_testnet_version
66+
aztec-up #release_version
6767
```
6868

6969
### L1 Ethereum Node Access

docs/docs-network/setup/bootnode_operation.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ Create a `docker-compose.yml` file for your bootnode:
5858
```yaml
5959
services:
6060
aztec-bootnode:
61-
image: "aztecprotocol/aztec:#include_testnet_version"
61+
image: "aztecprotocol/aztec:#release_version"
6262
container_name: "aztec-bootnode"
6363
ports:
6464
- ${P2P_PORT}:${P2P_PORT}

docs/docs-network/setup/building_from_source.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -45,10 +45,10 @@ cd aztec-packages
4545

4646
### Step 2: Check Out a Version Tag
4747

48-
Check out the version tag you want to build. For example, to build version #include_testnet_version:
48+
Check out the version tag you want to build. For example, to build version #release_version:
4949

5050
```bash
51-
git checkout v#include_testnet_version
51+
git checkout v#release_version
5252
```
5353

5454
:::tip
@@ -150,11 +150,11 @@ The tag `aztecprotocol/release-image-base` must match exactly—the Dockerfile i
150150
Build the final node image, combining the runtime environment (Step 5) with your compiled code (Step 4):
151151

152152
```bash
153-
docker build -f release-image/Dockerfile --build-arg VERSION=#include_testnet_version -t aztec-local:#include_testnet_version .
153+
docker build -f release-image/Dockerfile --build-arg VERSION=#release_version -t aztec-local:#release_version .
154154
```
155155

156156
:::tip
157-
The tag `aztec-local:#include_testnet_version` avoids conflicts with the official Docker Hub image and clearly indicates this is a locally-built version.
157+
The tag `aztec-local:#release_version` avoids conflicts with the official Docker Hub image and clearly indicates this is a locally-built version.
158158
:::
159159

160160
**Build arguments:**
@@ -180,21 +180,21 @@ You should see your image listed:
180180

181181
```
182182
REPOSITORY TAG IMAGE ID CREATED SIZE
183-
aztec-local #include_testnet_version abc123def456 2 minutes ago 2.5GB
183+
aztec-local #release_version abc123def456 2 minutes ago 2.5GB
184184
```
185185

186186
### Verify Version
187187

188188
```bash
189-
docker run --rm aztec-local:#include_testnet_version --version
189+
docker run --rm aztec-local:#release_version --version
190190
```
191191

192-
Should display version #include_testnet_version.
192+
Should display version #release_version.
193193

194194
### Test Basic Functionality
195195

196196
```bash
197-
docker run --rm aztec-local:#include_testnet_version --help
197+
docker run --rm aztec-local:#release_version --help
198198
```
199199

200200
Should display CLI help information without errors.
@@ -256,7 +256,7 @@ If all checks pass, your image is ready to use.
256256

257257
**Solutions**:
258258
- Ensure you used `--build-arg VERSION=X.Y.Z` when building the release image
259-
- The version should match the git tag without the 'v' prefix (e.g., `#include_testnet_version` not `v#include_testnet_version`)
259+
- The version should match the git tag without the 'v' prefix (e.g., `#release_version` not `v#release_version`)
260260

261261
## Using Your Custom Build
262262

@@ -267,7 +267,7 @@ Use your locally-built image with any node setup method. For Docker Compose, upd
267267
```yaml
268268
services:
269269
aztec-node:
270-
image: "aztec-local:#include_testnet_version"
270+
image: "aztec-local:#release_version"
271271
# ... rest of configuration
272272
```
273273

@@ -278,7 +278,7 @@ See [Running a Full Node](./running_a_node.md) for complete setup instructions.
278278
Run the Aztec CLI directly from your custom image:
279279

280280
```bash
281-
docker run --rm aztec-local:#include_testnet_version --version
281+
docker run --rm aztec-local:#release_version --version
282282
```
283283

284284
## Alternative Approaches

docs/docs-network/setup/running_a_node.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ These requirements are subject to change as the network throughput increases.
2525

2626
**Before proceeding:** Ensure you've reviewed and completed the [prerequisites](../prerequisites.md).
2727

28-
This setup includes only essential settings. The `--network testnet` flag applies network-specific defaults—see the [CLI reference](../reference/cli_reference.md) for all available configuration options.
28+
This setup includes only essential settings. The `--network #release_network` flag applies network-specific defaults—see the [CLI reference](../reference/cli_reference.md) for all available configuration options.
2929

3030
## Setup
3131

@@ -72,7 +72,7 @@ Create a `docker-compose.yml` file in your `aztec-node` directory:
7272
```yaml
7373
services:
7474
aztec-node:
75-
image: "aztecprotocol/aztec:#include_testnet_version"
75+
image: "aztecprotocol/aztec:#release_version"
7676
container_name: "aztec-node"
7777
ports:
7878
- ${AZTEC_PORT}:${AZTEC_PORT}
@@ -97,7 +97,7 @@ services:
9797
start
9898
--node
9999
--archiver
100-
--network testnet
100+
--network #release_network
101101
networks:
102102
- aztec
103103
restart: always

0 commit comments

Comments
 (0)