Automic VaultAutomic Vault

brew

使用 Homebrew, apk, Nix, pacman 安装 cargo-edit

查看 cargo-edit 的安装路径、可执行文件、元数据以及面向 AI 代理工作流的安全说明。

安装

其他安装命令

macOS

Homebrew已验证 · 100%
brew install cargo-edit

local Homebrew formula metadata

Linux

Alpine Linux apk已验证 · 92%
sudo apk add cargo-edit

Alpine Linux edge package indexes · cargo-edit · 来源: dl-cdn.alpinelinux.org

Nix已验证 · 92%
nix profile install nixpkgs#cargo-edit

nixpkgs package indexes · pkgs/by-name/ca/cargo-edit/package.nix · 来源: api.github.com

Arch Linux pacman已验证 · 92%
sudo pacman -S cargo-edit

Arch Linux sync databases · cargo-edit · 来源: geo.mirror.pkgbuild.com

概览

软件包摘要

Utility for managing cargo dependencies from the command-line

命令和别名

  • cargo-add
  • cargo-rm
  • cargo-set-version
  • cargo-upgrade

历史

项目历史与用法

cargo-edit is one of the historically important Cargo extension suites: it brought command-line editing of Cargo.toml dependencies, removals, upgrades, and package versions into common Rust workflows before parts of that behavior were absorbed by Cargo itself.

项目历史

The GitHub repository was created in June 2015, early in Rust's post-1.0 package ecosystem, and the crate was published on crates.io in November 2015. Its README describes a tool that extends Cargo with commands for adding, removing, upgrading, and versioning dependencies by modifying Cargo.toml.

cargo-edit originally shipped commands including `cargo add`, `cargo rm`, `cargo upgrade`, and `cargo set-version`. The README now records an important handoff: `cargo add` became integrated into Cargo as of Rust 1.62, and `cargo rm` as of Rust 1.66, while cargo-edit continues to provide commands such as `cargo upgrade` and `cargo set-version`.

采用历史

cargo-edit became a standard recommendation because Cargo itself long lacked ergonomic subcommands for editing dependency requirements in manifests. Its presence in Homebrew, Nix, Arch Linux, and Alpine packaging, plus millions of crates.io downloads, reflects broad adoption by Rust developers and CI images.

The upstreaming of `cargo add` and `cargo rm` into Cargo is the strongest adoption signal: workflows popularized by cargo-edit influenced the default Rust toolchain instead of remaining only third-party extensions.

使用方式

Historically, users installed cargo-edit to run commands such as `cargo add serde`, `cargo rm old-crate`, `cargo upgrade`, and `cargo set-version 1.0.0`. Modern users mostly rely on Cargo's built-in add/remove commands and keep cargo-edit for dependency requirement upgrades and manifest version changes.

`cargo upgrade` changes version requirements in Cargo.toml, while `cargo update` only updates versions selected in Cargo.lock. That distinction is central to why cargo-edit remains useful for package-maintenance work.

为什么软件包爱好者会关心

cargo-edit is package-nerd canon because it sits at the exact boundary between package-manager UX and manifest syntax. It made Rust dependency declarations feel more like `npm install` or `go get` workflows while still editing Cargo.toml explicitly.

Its history also shows how successful extension commands can become part of the base package manager once the workflow proves itself.

时间线

  • 2015: killercup/cargo-edit GitHub repository created.
  • 2015: cargo-edit crate first published on crates.io.
  • 2022: Cargo 1.62 integrated `cargo add`, according to the cargo-edit README.
  • 2022: Cargo 1.66 integrated `cargo rm`, according to the cargo-edit README.
  • 2026: crates.io metadata shows ongoing releases in the 0.13.x line.

Related projects

  • Cargo is the package manager extended by cargo-edit and later absorbed some of its commands.
  • cargo-upgrade and cargo-set-version are the remaining command families documented by the README.
  • The README points to related Cargo extension commands including cargo-feature and cargo-override.

安全态势

风险级别:绿色

narrow executable package without higher-risk signals.

风险分类器

绿色 风险 · 低 置信度 · appliance

原因

  • narrow executable package without higher-risk signals

信号

  • metadata:no-higher-risk-signals

安装行为

  • formula 元数据中未记录 Homebrew post-install 钩子。
  • Homebrew bottle 元数据适用于 6 个平台目标。
  • 构建元数据列出 2 个构建依赖。

建议审查

在无人值守的代理使用前,请检查该工具是否读取明文凭据、写入远程状态、发布制品或调用插件。

可执行文件

已安装的可执行文件

命令类型暴露范围备注
cargo-addcli全局可执行文件
cargo-rmcli全局可执行文件
cargo-set-versioncli全局可执行文件
cargo-upgradecli全局可执行文件

新鲜度

版本和新鲜度

这些信号区分页生成时间、软件包管理器活动和上游发布比较。只有存在证据 URL 和可比较版本时,才会提示版本落后。

页面生成时间2026-07-25
管理器版本0.13.13
管理器更新时间2026-07-15
本地数据OK
上游当前
检测到的最新版本v0.13.13

https://github.com/killercup/cargo-edit

  • OK没有生成新鲜度警告。

安装元数据

软件包元数据

软件包键brew:cargo-edit
版本0.13.13
软件包管理器Homebrew
软件包管理器页面https://formulae.brew.sh/formula/cargo-edit
主页https://killercup.github.io/cargo-edit/
仓库https://github.com/killercup/cargo-edit
上游文档https://killercup.github.io/cargo-edit
许可证MIT
源码归档https://github.com/killercup/cargo-edit/archive/refs/tags/v0.13.13.tar.gz
最后更新2026-07-15T20:49:45Z
Pulseupdated
构建依赖pkgconf, rust
Bottle可用 (于 arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sonoma, x86_64_linux)
Homebrew post-install未定义
服务未声明

注册表事实

源数据库详情

Source DatabaseHomebrew formula API
Taphomebrew/core
Full Namecargo-edit
Version Scheme0
Revision0
Bottle Stable Root URLhttps://ghcr.io/v2/homebrew/core
Deprecatedno
Disabledno
Keg Onlyno
URL Keys
  • stable

源数据库匹配

其他软件包管理器记录

匹配项来自外部软件包管理器索引,并与本地 Automic Vault 软件包链接分开显示。

Nix95%

cargo-edit

nix profile install nixpkgs#cargo-edit
  • normalized package name match
  • 匹配方式:Cargo Edit
nixpkgs package indexes · api.github.com · nixpkgs package indexes: pkgs/by-name/ca/cargo-edit/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
apk95%

cargo-edit 0.13.10-r0

Managing cargo dependencies from the command line

https://github.com/killercup/cargo-edit

sudo apk add cargo-edit
  • License: MIT OR Apache-2.0
  • Architecture: x86_64
  • Source Package: cargo-edit
  • 1 依赖
  • 1 提供
  • normalized package name match
  • 匹配方式:Cargo Edit
Alpine Linux edge package indexes · dl-cdn.alpinelinux.org · Alpine Linux edge package indexes: cargo-edit from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz
apk95%

cargo-edit-doc 0.13.10-r0

Managing cargo dependencies from the command line (documentation)

https://github.com/killercup/cargo-edit

sudo apk add cargo-edit-doc
  • License: MIT OR Apache-2.0
  • Architecture: x86_64
  • Source Package: cargo-edit
  • normalized package name match
  • 匹配方式:Cargo Edit
Alpine Linux edge package indexes · dl-cdn.alpinelinux.org · Alpine Linux edge package indexes: cargo-edit-doc from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz
pacman95%

cargo-edit 0.13.11-1

Managing cargo dependencies from the command line

https://github.com/killercup/cargo-edit/releases

sudo pacman -S cargo-edit
  • License: MIT AND Apache-2.0
  • Architecture: x86_64
  • 3 依赖
  • normalized package name match
  • 匹配方式:Cargo Edit
Arch Linux sync databases · geo.mirror.pkgbuild.com · Arch Linux sync databases: cargo-edit from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz

来源线索

由仓库数据生成

此页面由 av-webscripts/generate-pkg-sqlite.py 生成的私有软件包 SQLite 工件提供。

使用的来源

  • Geiger risk classifier
  • Nucleus package database
  • av.db category and tag curation
  • cross-ecosystem install command graph
  • curated package history
  • external package-manager database matches
  • package relationship graph
  • package version freshness
  • package-page enrichment