# 使用 Homebrew, Nix 安装 nak

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

## 安装

```sh
sudo av install brew:nak
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install nak
```

  证据: local Homebrew formula metadata

### Linux

- Nix (92%):

```sh
nix profile install nixpkgs#nak
```

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

## 软件包事实

- **软件包键:** brew:nak
- **软件包管理器:** Homebrew
- **软件包管理器页面:** <https://formulae.brew.sh/formula/nak>
- **版本:** 0.20.0
- **来源摘要:** CLI for doing all things nostr
- **主页:** <https://github.com/fiatjaf/nak>
- **仓库:** <https://github.com/fiatjaf/nak>
- **上游文档:** <https://github.com/fiatjaf/nak#readme>
- **许可证:** Unlicense
- **源码归档:** <https://github.com/fiatjaf/nak/archive/refs/tags/v0.20.0.tar.gz>
- **最后更新:** 2026-06-21T12:35:56Z
- **已生成:** 2026-07-08T18:08:21+00:00

## 可执行文件

- nak (cli)
- nak (别名)

## 构建依赖

- go

## 安装行为

- post-install 钩子: 未定义
- Bottle: 可用 于 arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sonoma, x86_64_linux

## 版本和新鲜度

- 页面生成时间: 2026-07-08
- 管理器版本: 0.20.0
- 管理器更新时间: 2026-06-21
- 本地数据: OK
- 上游仓库: https://github.com/fiatjaf/nak
- 检测到的最新版本: v0.20.0 (当前)
## 项目历史与用法

nak is fiatjaf's "nostr army knife": a Go command-line tool for creating, signing, publishing, querying, validating, and otherwise plumbing Nostr protocol events.

### 项目历史

The GitHub repository was created on 2022-02-09, during the early growth period of the Nostr ecosystem. Its README presents it as a general-purpose command-line tool for Nostr work, installable via a shell installer, Go, binaries, Homebrew, Arch, and Nix.

The release stream shows active maintenance through the 0.19 and 0.20 series, including v0.20.0 on 2026-06-21. That cadence fits a protocol utility that follows NIP additions and real relay/client usage rather than a one-off demo.

### 采用历史

nak's audience is narrower than mainstream networking tools, but it sits in an important niche for Nostr developers and power users. The repository metadata consulted on 2026-07-01 showed 389 GitHub stars and 46 forks, and the Homebrew page listed 673 installs over the prior 365 days.

Its adoption is tied to Nostr's preference for simple event and relay primitives: a CLI that can emit JSON, sign events, query relays, manage keys, and script relay operations is useful for debugging clients, writing shell workflows, and testing protocol behavior.

### 使用方式

The README examples show the core workflow: `nak event` creates a signed event; options can set secret keys, content, tags, timestamps, and relay targets; `nak req` queries relays and emits JSON that users commonly pipe to tools like `jq`.

Package nerds reach for nak when they want a reproducible Nostr command in a script: publish a test note, inspect relay responses, validate an event, talk to relay management APIs, experiment with bunker/nsec flows, or use Nostr as a transport for other artifacts.

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

nak is significant less as a mass-market CLI and more as a protocol workbench. It gives Nostr's event model a Unix-shaped interface, which is exactly what packagers and shell people want when a network protocol is still evolving.

### 时间线

- 2022-02-09: GitHub repository created.
- 2026-06-21: v0.20.0 release published.
- 2026-07-01: Homebrew Formulae page listed version 0.20.0 and 673 installs over the prior 365 days.

### Related projects

- Nostr
- nostr-tools
- noscl

### 来源

- <https://api.github.com/repos/fiatjaf/nak>
- <https://api.github.com/repos/fiatjaf/nak/releases?per_page=5>
- <https://formulae.brew.sh/formula/nak>
- <https://github.com/fiatjaf/nak>
- <https://stuff.fiatjaf.com/>


## 安全说明

没有找到 nak 的匹配本地密钥处理 manifest。Nucleus 软件包元数据仍在此发布，以便未来覆盖拥有稳定的软件包 URL。


## 源数据库详情

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** nak
- **Version Scheme:** 0
- **Revision:** 0
- **Head Version:** HEAD
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** head, stable

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

- Nix - nak: normalized package name match | nixpkgs package indexes: pkgs/by-name/na/nak/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1


## 相关链接

- [Source-control packages](https://www.automicvault.com/zh-hans/pkg/source-control-tools/) - Belongs to a source-control command family.
- [Terminal utility packages](https://www.automicvault.com/zh-hans/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Language runtime packages](https://www.automicvault.com/zh-hans/pkg/language-runtime-packages/) - Matched language runtime, compiler, or interpreter metadata.
- [Networking and protocol packages](https://www.automicvault.com/zh-hans/pkg/networking-protocol-tools/) - Matched network, protocol, or remote-service metadata.
- [go](https://www.automicvault.com/zh-hans/pkg/brew/go/) - Build dependency declared by Homebrew.
- [goat](https://www.automicvault.com/zh-hans/pkg/brew/goat/) - Shares av.db curated category or tags: cli, go, networking.
- [gost](https://www.automicvault.com/zh-hans/pkg/brew/gost/) - Shares av.db curated category or tags: cli, go, networking.
- [hysteria](https://www.automicvault.com/zh-hans/pkg/brew/hysteria/) - Shares av.db curated category or tags: cli, networking, relay.
- [mihomo](https://www.automicvault.com/zh-hans/pkg/brew/mihomo/) - Shares av.db curated category or tags: cli, go, networking.
- [socat](https://www.automicvault.com/zh-hans/pkg/brew/socat/) - Shares av.db curated category or tags: cli, networking, relay.
- [trojan-go](https://www.automicvault.com/zh-hans/pkg/brew/trojan-go/) - Shares av.db curated category or tags: cli, go, networking.
- [zns](https://www.automicvault.com/zh-hans/pkg/brew/zns/) - Shares av.db curated category or tags: cli, go, networking.
- [aerleon](https://www.automicvault.com/zh-hans/pkg/brew/aerleon/) - Shares av.db curated category or tags: cli, networking.
- [bombardier](https://www.automicvault.com/zh-hans/pkg/brew/bombardier/) - Both packages touch the same language runtime or ecosystem. Shared terms: cli, go, networking.

## Combined YAML source

View the package source record on GitHub. [combined/nak.yml](https://github.com/automic-vault/db/blob/main/combined/nak.yml)


## 来源

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