All apps/Foundry

Foundry

forge

A blazing fast, portable and modular toolkit for Ethereum application development written in Rust.

Runs as forge, cast, anvil, chisel|macOS, Linux, Windows|getfoundry.sh

Command form

ai-draft · 8 tasks · 29 fields

Build, test and initialize Solidity projects with Foundry's forge. Only a few common options of forge build, forge test and forge init are covered; fuzzing, invariant, fork, debugger and watch options are left out.

Opens the form; the finished command lands at your prompt, unrun
otty gui forge

forge build

Build contracts

Compile the project's smart contracts.

Build contractsExample values, fixed in this page — nothing here reaches a terminal
TasksEach one presets the form for one job
Build project
Build and print sizes
sizes
Clean rebuild
force
ParametersOnly these flags are editable in the form
Paths
Files or directories to build; empty builds the whole project.
path · positional 0 · repeatable
Print contract sizes
boolean
--sizes
Print contract names
boolean
--names
Clean and recompile
Clear the cache and artifacts folder, then recompile everything.
boolean
--force
Solc version
A version such as 0.8.28, a path, or an executable name.
string
--use
Use Yul IR pipeline
boolean
--via-ir
EVM version
string
--evm-version
Artifacts folder
path
--out-o
Project root
path
--root
Offline
Do not access the network; missing solc versions are not installed.
boolean
--offline

forge test

Run tests

Run the project's tests, optionally filtered by test, contract or path.

Run testsExample values, fixed in this page — nothing here reaches a terminal
TasksEach one presets the form for one job
Run all tests
Run one test with traces
match_testverbosity
Run one contract
match_contract
ParametersOnly these flags are editable in the form
Match test
Regex of test function names to run.
string
--match-test
Exclude test
Regex of test function names to skip.
string
--no-match-test
Match contract
Regex of contract names to run.
string
--match-contract
Exclude contract
string
--no-match-contract
Match path
Glob of source files to run.
string
--match-path
Verbosity
Repeat -v to show more detail, e.g. -vvvv for traces.
count
-v
Gas report
boolean
--gas-report
Fuzz runs
integer
--fuzz-runs
Stop at first failure
boolean
--fail-fast
List tests only
boolean
--list-l
JSON output
boolean
--json

forge init

Create a project

Create a new Forge project.

Create a projectExample values, fixed in this page — nothing here reaches a terminal
Basic
Project directory*
directory
TasksEach one presets the form for one job
New project
path
New project without examples
pathempty
ParametersOnly these flags are editable in the form
Project directory
path · positional 0
Template
A template repository to start from.
string
--template-t
No example contracts
boolean
--empty
VS Code settings
boolean
--vscode
Vyper template
boolean
--vyper
Offline
Do not install dependencies from the network.
boolean
--offline
Skip git submodule
boolean
--no-git
Allow non-empty directory
boolean
--force
SourcesEvery flag above is checked against these
help
Usage: forge build [OPTIONS] [PATHS]... --names Print compiled contract names --sizes Print compiled contract sizes. Constructor argument length is not --force Clear the cache and artifacts folder and recompile --use <SOLC_VERSION> Specify the solc version, path, or executable name on `PATH` to…
help2026-10-27

www.getfoundry.sh

help
Usage: forge test [OPTIONS] [PATH] -v, --verbosity... -l, --list List tests instead of running them --gas-report Print a gas report --allow-failure Exit with code 0 even if a test fails --fail-fast Stop running tests after the first failure --fuzz-runs <RUNS> --match-test <REGEX>…
help2026-10-27

www.getfoundry.sh

help
[PATH] The root directory of the new project -t, --template <TEMPLATE> The template to start from --offline Do not install dependencies from the network --force Create the project even if the specified root directory is not empty --vscode Create a .vscode/settings.json file with Solidity…
help2026-10-27

www.getfoundry.sh

Before it fills your prompt, Otty checks the installed forge against its version. A form that does not match your version is not offered.