Skip to content
This repository was archived by the owner on May 4, 2026. It is now read-only.

Commit 0681cdd

Browse files
committed
modified flags to match devnet
2 parents 58209f1 + b8a96c0 commit 0681cdd

5 files changed

Lines changed: 57 additions & 35 deletions

File tree

documentation/cli/00_overview.md

Lines changed: 18 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -25,23 +25,24 @@ You can print the list of commands by running `leo --help`
2525
- [`debug`](./05_debug.md) - Run the interactive debugger in the current package.
2626
- [`deploy`](./06_deploy.md) - Deploy a program to the Aleo network.
2727
- [`devnet`](./07_devnet.md) - Initialize a local devnet.
28-
- [`execute`](./08_execute.md) - Execute a program and produce a transaction containing a proof.
29-
- [`new`](./09_new.md) - Create a new Leo project in a new directory.
30-
- [`query`](./10_query.md) - Query live data and state from the Aleo network.
31-
- [`block`](./10_query.md#leo-query-block) - Query block information.
32-
- [`transaction`](./10_query.md#leo-query-transaction) - Query transaction information.
33-
- [`program`](./10_query.md#leo-query-program) - Query program source code and live mapping values.
34-
- [`stateroot`](./10_query.md#leo-query-stateroot) - Query the latest stateroot.
35-
- [`committee`](./10_query.md#leo-query-committee) - Query the current committee.
36-
- [`mempool`](./10_query.md#leo-query-mempool) - Query transactions and transmissions from the memory pool.
37-
- [`peers`](./10_query.md#leo-query-peers) - Query peer information.
38-
- [`remove`](./11_remove.md) - Remove a dependency from the current project.
39-
- [`run`](./12_run.md) - Run a program without producing a proof.
40-
- [`test`](./13_test.md) - Run the test cases for a Leo project.
41-
- [`update`](./14_update.md) - Update to the latest version of Leo.
42-
- [`upgrade`](./15_upgrade.md) - Upgrade a deployed program on the Aleo network.
43-
- [`synthesize`](./16_synthesize.md) - Generate proving and verifying keys for a program.
44-
- [`fmt`](./17_fmt.md) - Format Leo source files.
28+
- [`devnode`](./08_devnode.md) - Run a local lightweight devnode.
29+
- [`execute`](./09_execute.md) - Execute a program and produce a transaction containing a proof.
30+
- [`new`](./10_new.md) - Create a new Leo project in a new directory.
31+
- [`query`](./11_query.md) - Query live data and state from the Aleo network.
32+
- [`block`](./11_query.md#leo-query-block) - Query block information.
33+
- [`transaction`](./11_query.md#leo-query-transaction) - Query transaction information.
34+
- [`program`](./11_query.md#leo-query-program) - Query program source code and live mapping values.
35+
- [`stateroot`](./11_query.md#leo-query-stateroot) - Query the latest stateroot.
36+
- [`committee`](./11_query.md#leo-query-committee) - Query the current committee.
37+
- [`mempool`](./11_query.md#leo-query-mempool) - Query transactions and transmissions from the memory pool.
38+
- [`peers`](./11_query.md#leo-query-peers) - Query peer information.
39+
- [`remove`](./12_remove.md) - Remove a dependency from the current project.
40+
- [`run`](./13_run.md) - Run a program without producing a proof.
41+
- [`test`](./14_test.md) - Run the test cases for a Leo project.
42+
- [`update`](./15_update.md) - Update to the latest version of Leo.
43+
- [`upgrade`](./16_upgrade.md) - Upgrade a deployed program on the Aleo network.
44+
- [`synthesize`](./17_synthesize.md) - Generate proving and verifying keys for a program.
45+
- [`fmt`](./18_fmt.md) - Format Leo source files.
4546

4647
## Universal Flags
4748

documentation/cli/05_debug.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,4 @@ sidebar_label: Debug
1212
`leo debug` has been removed in Leo 4.0. The interactive interpreter is no longer available.
1313
:::
1414

15-
For testing and debugging your Leo programs, use [`leo test`](13_test.md), which runs your test suite against the real VM. For integration testing against a live network or a local devnet, use the [SDK](https://github.com/ProvableHQ/sdk) directly.
15+
For testing and debugging your Leo programs, use [`leo test`](14_test.md), which runs your test suite against the real VM. For integration testing against a live network or a local devnet, use the [SDK](https://github.com/ProvableHQ/sdk) directly.

documentation/cli/08_devnode.md

Lines changed: 36 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,17 @@ toc_min_heading_level: 2
66
toc_max_heading_level: 2
77
---
88

9-
[general tags]: # "cli, leo_devnode, devnode local_devnode"
9+
[general tags]: # "cli, leo_devnode, devnode, local_devnode"
1010

1111
# `leo devnode`
1212

13-
Leo devnode is a lightweight-node network that bypasses the consensus algorithm and the requirement to generate proofs for deployment and execution transactions. It is a development tool intended for rapidly iterating on Aleo program design and running end-to-end tests prior to deploying Aleo programs to testnet and mainnet.
13+
A devnode is a lightweight-node network that bypasses the consensus algorithm and the requirement to generate proofs for deployment and execution transactions. It is a development tool intended for rapidly iterating on Aleo program design and running end-to-end tests prior to deploying Aleo programs to Testnet and Mainnet.
1414

15-
To initialize devnode, run the following command:
15+
:::note
16+
`leo devnode` is the recommended local development tool for lightweight testing. The older [`leo devnet`](./07_devnet.md) command (which requires a full snarkOS installation and spins up a multi-validator network) remains available for more complex testing scenarios.
17+
:::
18+
19+
To initialize a devnode, run the following command:
1620

1721
```bash
1822
leo devnode start --private-key <PRIVATE_KEY>
@@ -26,7 +30,7 @@ The default endpoint for a local devnode is `http://localhost:3030`.
2630

2731
<!-- markdown-link-check-enable -->
2832

29-
Press `Ctrl+C` to stop the devnode. If started with persistent storage (`-l`), the ledger state is saved and can be resumed by running `leo devnode start -l` again. If started without persistent storage, the ledger is discarded when the devnode exits.
33+
Press `Ctrl+C` to stop the devnode. If started with `--ledger-path`, the ledger state is saved and can be resumed by running the same command again. If started without `--ledger-path`, the ledger is discarded when the devnode exits.
3034

3135
## `leo devnode start`
3236

@@ -36,20 +40,26 @@ leo devnode start [OPTIONS]
3640

3741
| Flag | Short | Default | Description |
3842
|------|-------|---------|-------------|
39-
| `--private-key` | `-p` | | Private key (required, or set via environment variable) |
43+
| `--private-key` | | | Private key (required, or set via `PRIVATE_KEY` environment variable) |
4044
| `--verbosity` | `-v` | `2` | Log verbosity level (`0``2`) |
4145
| `--socket-addr` | `-a` | `127.0.0.1:3030` | Address and port for the REST API |
4246
| `--genesis-path` | `-g` | (built-in) | Path to a custom genesis block file |
4347
| `--manual-block-creation` | `-m` | `false` | Disable automatic block creation after broadcast |
48+
<<<<<<< HEAD
4449
| `--storage` | `-s` | (in-memory) | Directory for persistent ledger storage. If `-l` is given without a path, defaults to `./devnode/` |
4550
| `--clear-storage` | `-c` | `false` | Clear the ledger directory before starting. Requires `--storage` |
51+
=======
52+
| `--ledger-path` | `-l` | (in-memory) | Path for persistent ledger storage. If `-l` is given without a path, defaults to `./devnode` |
53+
| `--clean` | `-c` | `false` | Clear the ledger directory before starting. Requires `--ledger-path` |
54+
>>>>>>> b8a96c0d62f165a26a91d2d23c18bae88f72a67e
4655
47-
**Examples**
56+
### **Examples**
4857

4958
```bash
5059
# In-memory (ephemeral, no persistence)
51-
leo devnode start
60+
leo devnode start --private-key APrivateKey1zkp8CZNn3yeCseEtxuVPbDCwSyhGW6yZKUYKfgXmcpoGPWH
5261

62+
<<<<<<< HEAD
5363
# Persistent, default directory (./devnode/)
5464
leo devnode start -s
5565

@@ -59,9 +69,20 @@ leo devnode start -s ./my-ledger
5969
# Fresh start — wipe existing ledger before starting
6070
leo devnode start -s --c
6171
leo devnode start -s ./my-ledger -c
72+
=======
73+
# Persistent, default directory (./devnode)
74+
leo devnode start --private-key APrivateKey1zkp8CZNn3yeCseEtxuVPbDCwSyhGW6yZKUYKfgXmcpoGPWH -l
75+
76+
# Persistent, custom directory
77+
leo devnode start --private-key APrivateKey1zkp8CZNn3yeCseEtxuVPbDCwSyhGW6yZKUYKfgXmcpoGPWH -l ./my-ledger
78+
79+
# Fresh start — wipe existing ledger before starting
80+
leo devnode start --private-key APrivateKey1zkp8CZNn3yeCseEtxuVPbDCwSyhGW6yZKUYKfgXmcpoGPWH -l --clean
81+
leo devnode start --private-key APrivateKey1zkp8CZNn3yeCseEtxuVPbDCwSyhGW6yZKUYKfgXmcpoGPWH -l ./my-ledger --clean
82+
>>>>>>> b8a96c0d62f165a26a91d2d23c18bae88f72a67e
6283

6384
# Manual block creation (blocks only advance when explicitly requested)
64-
leo devnode start -m
85+
leo devnode start --private-key APrivateKey1zkp8CZNn3yeCseEtxuVPbDCwSyhGW6yZKUYKfgXmcpoGPWH -m
6586
```
6687

6788
## `leo devnode advance`
@@ -77,7 +98,7 @@ leo devnode advance [NUM_BLOCKS] [OPTIONS]
7798
| `NUM_BLOCKS` | `1` | Number of blocks to create |
7899
| `--socket-addr` | `127.0.0.1:3030` | Address of the running devnode |
79100

80-
**Examples**
101+
### **Examples**
81102

82103
```bash
83104
# Advance by 1 block
@@ -90,27 +111,27 @@ leo devnode advance 10
90111
leo devnode advance 5 --socket-addr 127.0.0.1:4040
91112
```
92113

93-
## Using Leo CLI Commands with Devnode
114+
## Skipping Proof Generation
94115

95116
When targeting a devnode, two proof-generation steps can be skipped for faster iteration. Proofs are not verified by the devnode, so generating them is unnecessary overhead.
96117

97-
**Deploying a program**
118+
### **Deploying a Program**
98119

99120
```bash
100121
leo deploy --skip-deploy-certificate --endpoint http://localhost:3030
101122
```
102123

103124
`--skip-deploy-certificate` skips generating the deployment proof. Without it, deployment will still work but will be significantly slower.
104125

105-
**Executing a transition**
126+
### **Executing a Transition**
106127

107128
```bash
108129
leo execute <TRANSITION> <INPUTS> --skip-execute-proof --endpoint http://localhost:3030
109130
```
110131

111132
`--skip-execute-proof` skips generating the execution proof. Without it, execution will still work but will be significantly slower.
112133

113-
**Upgrading a program**
134+
### **Upgrading a Program**
114135

115136
```bash
116137
leo upgrade --skip-deploy-certificate --endpoint http://localhost:3030
@@ -120,7 +141,7 @@ leo upgrade --skip-deploy-certificate --endpoint http://localhost:3030
120141

121142
```bash
122143
# 1. Start a persistent devnode
123-
leo devnode start -s
144+
leo devnode start --private-key APrivateKey1zkp8CZNn3yeCseEtxuVPbDCwSyhGW6yZKUYKfgXmcpoGPWH -s
124145

125146
# 2. Deploy your program (in another terminal, from your Leo project directory)
126147
leo deploy --skip-deploy-certificate --endpoint http://localhost:3030
@@ -129,5 +150,5 @@ leo deploy --skip-deploy-certificate --endpoint http://localhost:3030
129150
leo execute <TRANSITION> <INPUTS> --skip-execute-proof --endpoint http://localhost:3030
130151

131152
# 4. Reset and start fresh when needed
132-
leo devnode start -s -c
153+
leo devnode start --private-key APrivateKey1zkp8CZNn3yeCseEtxuVPbDCwSyhGW6yZKUYKfgXmcpoGPWH -s -c
133154
```

documentation/cli/13_run.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ toc_max_heading_level: 2
1010

1111
# `leo run`
1212

13-
You can run an entry function by using the `leo run` command. This will simply run the specified entry function with the provided inputs and show what the produced output will be. It will NOT generate the zero-knowledge proof of execution or the transaction, and nothing will be run onchain. For that, please see the [`leo execute`](08_execute.md) command.
13+
You can run an entry function by using the `leo run` command. This will simply run the specified entry function with the provided inputs and show what the produced output will be. It will NOT generate the zero-knowledge proof of execution or the transaction, and nothing will be run onchain. For that, please see the [`leo execute`](09_execute.md) command.
1414

1515
To run a Leo entry function with inputs from the command line, run the following command:
1616

documentation/guides/08_testing.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ or
163163
leo test addition
164164
```
165165

166-
See the `leo test` CLI documentation [here](./../cli/13_test.md)
166+
See the `leo test` CLI documentation [here](./../cli/14_test.md)
167167

168168
## Running a Devnet
169169

0 commit comments

Comments
 (0)