LinuxCommandLibrary

cargo-info

Display information about a Rust crate

TLDR

Show package information

$ cargo info [serde]
copy
Show specific version info
$ cargo info [serde@1.0]
copy
Show info for local package
$ cargo info
copy
Show info with features
$ cargo info [tokio]
copy

SYNOPSIS

cargo info [options] [spec]

DESCRIPTION

cargo info displays information about a package from crates.io or the local workspace. Shows metadata from Cargo.toml including name, version, description, license, dependencies, and features.
For local workspace packages, displays information from the local manifest. Creates Cargo.lock if it doesn't exist.

PARAMETERS

--registry name

Use specified registry
--index url
Use specified registry index
--manifest-path path
Path to Cargo.toml
-v, --verbose
Verbose output
-q, --quiet
Suppress output

OUTPUT

Displays:
- Package name and version
- Description
- License
- Documentation and repository links
- Dependencies
- Features
- Recent versions

CAVEATS

Without version specification, selects version based on Minimum Supported Rust Version (MSRV). For more detailed crate queries, consider cargo-crate or cargo-information.

SEE ALSO

> TERMINAL_GEAR

Curated for the Linux community

Copied to clipboard

> TERMINAL_GEAR

Curated for the Linux community