Skip to main content

arc command reference

arc manages Argon libraries. It reads Argon.toml to find the source, technology file, dependencies, and GDS imports, so you don't pass them on the command line.

arc new​

arc new <PATH> [--name <NAME>]
ArgumentRequiredDescription
<PATH>YesDirectory to create. Must not already exist. Its last component is the default library name.
--name <NAME>NoLibrary name to write to Argon.toml instead.

Creates Argon.toml, lib.ar, and tech.toml.

arc new my-layout
arc new layouts/demo --name demo

arc fmt​

arc fmt [--manifest-path <PATH>] [--check]
OptionDefaultDescription
--manifest-path <PATH>Nearest manifestLibrary to format.
--checkOffReport unformatted files and exit non-zero, without changing them.
arc fmt
arc fmt --check

arc check​

arc check [--manifest-path <PATH>] [--argonc <PATH>]
OptionDefaultDescription
--manifest-path <PATH>Argon.tomlLibrary to check.
--argonc <PATH>ARGONC or argoncCompiler executable to use.

Parses, resolves, and type-checks the library without running a cell. No technology file is needed.

arc run​

arc run --cell <EXPR> [--output <PATH>] [--gds | --gds-only] [--spice] [--spectre] [--netlist-width <COLS>]
OptionRequired/defaultDescription
--cell <EXPR>RequiredCell to run, such as top(10., 20.). Arguments are Argon expressions evaluated in the library's scope.
-o, --output <PATH>target/argon.binWhere to write the compiled layout.
--gdsOffAlso write target/argon.gds.
--gds-onlyOffWrite only target/argon.gds, without the compiled layout the editor opens. Uses much less memory, so it suits generating large layouts.
--spiceOffAlso write a SPICE netlist to target/argon.spice.
--spectreOffAlso write a Spectre netlist to target/argon.scs.
--netlist-width <COLS>80Break netlist lines longer than this many characters; 0 turns wrapping off. Requires --spice or --spectre.
--manifest-path <PATH>Argon.tomlLibrary to run.
--argonc <PATH>ARGONC or argoncCompiler executable to use.
arc run --cell 'top(10., 20.)'
arc run --cell 'top(10., 20.)' --gds
arc run --cell 'top(10., 20.)' --gds-only
arc run --cell 'inv(2., 1., 2)' --spice --spectre
tip

Quote the cell expression so the shell doesn't interpret the parentheses.

Netlists are described in Schematics.

arc doc​

arc doc [--manifest-path <PATH>] [--output <DIR>]
OptionDefaultDescription
--manifest-path <PATH>Nearest manifestLibrary to document.
-o, --output <DIR>target/docWhere to write the generated site.

Generates a standalone HTML reference for the library, one page per module, with signatures, argument tables, enum variants, source locations, and links between the library's own types. Documentation comes from //! module comments and /// declaration comments. Doctests are not run.

lib.ar
//! Standard cells for this library.

use std::layout::rect;

/// Draws a square on the requested layer.
///
/// # Arguments
/// - `layer`: technology layer name.
/// - `size`: square edge length.
cell square(layer: String, size: Float) {
rect(layer, x0=0., y0=0., w=size, h=size);
}
arc doc
open target/doc/index.html