# 使用 Homebrew, apk, chocolatey, apt, dnf, MacPorts, Nix, zypper, scoop 安装 ack

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

## 安装

```sh
sudo av install brew:ack
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install ack
```

  证据: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install ack
```

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

### Linux

- apk (92%):

```sh
sudo apk add ack
```

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

- Debian apt (92%):

```sh
sudo apt install ack
```

  证据: Debian stable package indexes: ack from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz

- dnf (92%):

```sh
sudo dnf install ack
```

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

- Nix (92%):

```sh
nix profile install nixpkgs#ack
```

  证据: nixpkgs package indexes: ack from https://raw.githubusercontent.com/NixOS/nixpkgs/master/pkgs/top-level/all-packages.nix

- zypper (92%):

```sh
sudo zypper install ack
```

  证据: openSUSE Tumbleweed package metadata: ack from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst

### Windows

- Chocolatey (92%):

```sh
choco install ack
```

  证据: Chocolatey community package catalog: ack from https://community.chocolatey.org/api/v2/Packages()?$filter=IsLatestVersion&$select=Id&$top=1000

- Scoop (92%):

```sh
scoop install main/ack
```

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

## 软件包事实

- **软件包键:** brew:ack
- **软件包管理器:** Homebrew
- **版本:** 3.10.0
- **来源摘要:** Search tool like grep, but optimized for programmers
- **主页:** <https://beyondgrep.com/>
- **仓库:** <https://github.com/beyondgrep/ack3>
- **最后更新:** 2026-06-22T14:02:41-07:00
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- ack (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

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

ack is a Perl-based source-code search tool, similar to grep but optimized for programmers searching large source trees.

### 项目历史

ack was written and maintained by Andy Lester. The ack3 README describes it as a code-searching tool similar to grep, portable across platforms that run Perl.

The project evolved through major release lines: ack 2.0 in 2013 changed default search behavior and ackrc handling, and ack 3.0 in 2019 was the first official ack 3 release.

### 采用历史

ack spread through developer package managers because it gave programmers grep-like searching with recursive traversal, source-file type detection, VCS-directory ignores, highlighting, and project/user configuration.

The input package facts list ack across Homebrew, Debian, Ubuntu, Fedora/dnf, MacPorts, Nix, Scoop, Chocolatey, Alpine, and openSUSE/zypper, showing unusually broad cross-platform packaging for a small CLI.

### 使用方式

Typical usage is interactive and recursive, for example running ack PATTERN inside a source tree. The official documentation emphasizes default recursion, source-aware file selection, filetype filters, match highlighting, and GNU grep-like switches.

ack reads options from ackrc files, including global, user, project, and explicitly supplied ackrc locations, which lets users encode local filetype and ignore rules without wrapper scripts.

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

ack is important in CLI package history as one of the classic programmer-focused grep replacements, alongside later tools such as ag and ripgrep.

For package maintainers it is intentionally boring in a useful way: mostly Perl, few runtime assumptions, one main executable, and behavior that users expect to be identical across Unix, Windows, and package-manager installs.

### 时间线

- 2005: ack copyright history begins in the official ack3 README.
- 2013: ack 2.0 released with changed defaults and multiple ackrc support.
- 2019: ack 3.0.0 becomes the first official ack 3 release.
- 2026: ack 3.10.0 changelog records security fixes for ANSI escapes and project .ackrc handling.

### Related projects

- Related tools include grep, GNU grep, File::Next, The Silver Searcher, and ripgrep.

### 来源

- <https://beyondgrep.com/changes.txt>
- <https://beyondgrep.com/documentation/>
- <https://raw.githubusercontent.com/beyondgrep/ack2/dev/Changes>
- <https://raw.githubusercontent.com/beyondgrep/ack3/dev/README.md>
- source_facts.package-manager


## 安全说明

narrow executable package without higher-risk signals.

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


## Configuration and credential file locations

These source-backed paths show where this package keeps local settings or durable credentials. Automic Vault can use them as review targets for secret scanning, migration, and command approval.


## Configuration files

- Unix: ~/.ackrc, /etc/ackrc
- Windows: C:\Users\$USER\AppData\Roaming\ackrc, C:\ProgramData\ackrc
## 其他软件包管理器记录

- Debian apt - ack - 3.8.1-1: normalized package name match | Debian stable package indexes: ack from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | grep-like program specifically for large source trees | https://beyondgrep.com/
- Nix - ack: normalized package name match | nixpkgs package indexes: ack from https://raw.githubusercontent.com/NixOS/nixpkgs/master/pkgs/top-level/all-packages.nix
- Ubuntu apt - ack - 3.7.0-1: normalized package name match | Ubuntu 24.04 LTS package indexes: ack from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | grep-like program specifically for large source trees | https://beyondgrep.com/
- apk - ack - 3.10.0-r0: normalized package name match | Alpine Linux edge package indexes: ack from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | Perl-powered replacement for grep | https://beyondgrep.com/
- apk - ack-doc - 3.10.0-r0: normalized package name match | Alpine Linux edge package indexes: ack-doc from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | Perl-powered replacement for grep (documentation) | https://beyondgrep.com/
- dnf - ack - 3.10.0-2.fc45: normalized package name match | Fedora Rawhide package metadata: ack from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst | A Grep-like source code search tool | http://beyondgrep.com/
- zypper - ack - 3.10.0-1.3: normalized package name match | openSUSE Tumbleweed package metadata: ack from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst | Grep-Like Text Finder | https://beyondgrep.com/
- zypper - perl-App-Ack - 3.10.0-1.3: normalized package name match | openSUSE Tumbleweed package metadata: perl-App-Ack from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst | Grep-Like Text Finder Perl Module | https://beyondgrep.com/
- MacPorts - ack: normalized package name match | MacPorts ports tree: devel/ack/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1
- Chocolatey - ack: normalized package name match | Chocolatey community package catalog: ack from https://community.chocolatey.org/api/v2/Packages()?$filter=IsLatestVersion&$select=Id&$top=1000
- Scoop - main/ack: normalized package name match | Scoop official bucket manifest trees: bucket/ack.json from https://api.github.com/repos/ScoopInstaller/Main/git/trees/master?recursive=1


## Combined YAML source

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


## 来源

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