Expand description

Show and Edit Cargo’s Manifest Files

Semver Compatibility

cargo-edit’s versioning tracks compatibility for the binaries, not the API. We upload to crates.io to distribute the binary. If using this as a library, be sure to pin the version with a = version requirement operator. Note though that our goal is for cargo-edit to go away as we move things into cargo.

Structs

The CLI error is the error type used at Cargo’s CLI-layer.
User-specified crate
A dependency handled by Cargo
A Cargo manifest that is available locally.
A Cargo manifest
Dependency from a local path
Dependency from a registry

Enums

The set of available colors for the terminal foreground/background.
ColorChoice represents the color preferences of an end user.
Primary location of a dependency

Traits

Provides the context method for Result.
Additional version functionality

Functions

Whether to color logged output
If a manifest is specified, return that one, otherise perform a manifest search starting from the current directory. If a manifest is specified, return that one. If a path is specified, perform a manifest search starting from there. If nothing is specified, start searching from the current directory (cwd).
Find the highest version compatible with a version req
Get a dependency’s version from its entry in the dependency table
Query latest version from a registry index
Takes a pkgid and attempts to find the path to it’s Cargo.toml, using cargo’s metadata
Find the URL of a registry
Set a dependency’s version in its entry in the dependency table
Print a styled warning message.
Print a message with a colored title in the style of Cargo shell messages.
Print a styled action message.
Print a styled warning message.
Print a part of a line with formatting
update registry index for given project
Upgrade an existing requirement to a new version

Type Definitions

Common result type
CLI-specific result
Common error type