# 使用 Homebrew, dnf, MacPorts, pacman, apk, Nix, scoop, winget 安装 dua-cli

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

## 安装

```sh
sudo av install brew:dua-cli
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install dua-cli
```

  证据: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install dua-cli
```

  证据: MacPorts ports tree: sysutils/dua-cli/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1

### Linux

- dnf (92%):

```sh
sudo dnf install dua-cli
```

  证据: Fedora Rawhide package metadata: dua-cli from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst

- pacman (92%):

```sh
sudo pacman -S dua-cli
```

  证据: Arch Linux sync databases: dua-cli from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz

- apk (92%):

```sh
sudo apk add dua
```

  证据: Alpine Linux edge package indexes: dua from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz

- Nix (92%):

```sh
nix profile install nixpkgs#dua
```

  证据: nixpkgs package indexes: pkgs/by-name/du/dua/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

### Windows

- Scoop (92%):

```sh
scoop install main/dua
```

  证据: Scoop official bucket manifest trees: bucket/dua.json from https://api.github.com/repos/ScoopInstaller/Main/git/trees/master?recursive=1

- winget (92%):

```sh
winget install --id Byron.dua-cli -e
```

  证据: Windows Package Manager source index: Byron.dua-cli from https://cdn.winget.microsoft.com/cache/source.msix

## 软件包事实

- **软件包键:** brew:dua-cli
- **软件包管理器:** Homebrew
- **版本:** 2.41.0
- **来源摘要:** View disk space usage and delete unwanted data, fast
- **主页:** <https://lib.rs/crates/dua-cli>
- **仓库:** <https://github.com/Byron/dua-cli>
- **最后更新:** 2026-08-03T15:20:09Z
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- dua (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

- 页面生成时间: 2026-08-03
- 管理器版本: 2.41.0
## 项目历史与用法

dua-cli is a Rust disk-usage analyzer whose installed command is `dua`. It combines fast parallel directory scanning with an optional interactive terminal UI for exploring and deleting disk usage.

### 项目历史

The public GitHub repository was created in 2019, and crates.io records the crate shortly after. The README explains the name as 'Disk Usage Analyzer' and emphasizes parallel scanning that can saturate SSDs, plus an interactive mode designed with multi-stage deletion safeguards.

The project builds on Rust ecosystem libraries such as `jwalk` for parallel filesystem walking and `petgraph` for interactive graph handling. Its README also documents the removal of older terminal backend complexity in favor of crossterm.

### 采用历史

dua-cli is widely packaged for a Rust CLI of its size: Homebrew, MacPorts, Fedora, Arch, Nix, NetBSD/pkgsrc, Scoop, WinGet, Void Linux, Cargo, and binary release installers are all documented upstream. Crates.io metadata shows more than two hundred thousand total downloads, while Homebrew analytics show steady formula installs.

### 使用方式

Basic usage mirrors `du`: run `dua`, `dua *`, or `dua aggregate` to inspect directory sizes. The `dua interactive` or `dua i` mode opens a terminal browser for navigating large trees and deleting unwanted data with confirmation steps. The optional config file controls interactive behavior such as Escape-key navigation.

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

dua-cli is significant as part of the Rust replacement-tool lineage: a faster, friendlier take on classic Unix disk-usage workflows, packaged as a single CLI across many operating systems. It is also a useful comparison point against `du`, `ncdu`, `dust`, `gdu`, and graphical disk analyzers.

### 时间线

- 2019: Public Byron/dua-cli GitHub repository created.
- 2019: Crates.io records the `dua-cli` crate.
- 2020s: Upstream README documents installation through Homebrew, MacPorts, Cargo, Linux package managers, Scoop, WinGet, Nix, and binary releases.

### Related projects

- The README lists `du`, `dust`, `dutree`, `pdu`, `ncdu`, `gdu`, `godu`, GNOME Disk Usage Analyzer, and KDE Filelight as similar programs. It also acknowledges `jwalk` as a core reason the CLI could focus on user-facing behavior.

### 来源

- <https://github.com/Byron/dua-cli>
- <https://github.com/Byron/dua-cli#readme>
- <https://crates.io/api/v1/crates/dua-cli>
- <https://formulae.brew.sh/api/formula/dua-cli.json>


## 安全说明

narrow executable package without higher-risk signals.

- **Geiger 风险:** 绿色 / 低
- narrow executable package without higher-risk signals

## 其他软件包管理器记录

- dnf - dua-cli - 2.38.1-1.fc45: normalized package name match | Fedora Rawhide package metadata: dua-cli from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst | Tool to conveniently learn about the disk usage of directories | https://crates.io/crates/dua-cli
- pacman - dua-cli - 2.41.0-1: normalized package name match | Arch Linux sync databases: dua-cli from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz | A tool to conveniently learn about the disk usage of directories, fast! | https://github.com/Byron/dua-cli
- MacPorts - dua-cli: normalized package name match | MacPorts ports tree: sysutils/dua-cli/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1
- Nix - dua: installed executable or alias match | nixpkgs package indexes: pkgs/by-name/du/dua/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- apk - dua - 2.34.0-r0: installed executable or alias match | Alpine Linux edge package indexes: dua from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Tool to conveniently learn about the usage of disk space | https://github.com/Byron/dua-cli
- apk - dua-bash-completion - 2.34.0-r0: installed executable or alias match | Alpine Linux edge package indexes: dua-bash-completion from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Bash completions for dua | https://github.com/Byron/dua-cli
- apk - dua-fish-completion - 2.34.0-r0: installed executable or alias match | Alpine Linux edge package indexes: dua-fish-completion from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Fish completions for dua | https://github.com/Byron/dua-cli
- apk - dua-zsh-completion - 2.34.0-r0: installed executable or alias match | Alpine Linux edge package indexes: dua-zsh-completion from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Zsh completions for dua | https://github.com/Byron/dua-cli
- Scoop - main/dua: installed executable or alias match | Scoop official bucket manifest trees: bucket/dua.json from https://api.github.com/repos/ScoopInstaller/Main/git/trees/master?recursive=1
- winget - Byron.dua-cli: installed executable or alias match | Windows Package Manager source index: Byron.dua-cli from https://cdn.winget.microsoft.com/cache/source.msix


## Combined YAML source

View the package source record on GitHub. [combined/dua-cli.yml](https://github.com/mxcl/pkgdb/blob/main/combined/dua-cli.yml)


## 来源

- pkg.so package database
- Geiger risk classifier
- curated package history
- pkgdb category and tag curation
- external package-manager database matches
- cross-ecosystem install command graph
