# 使用 Homebrew, MacPorts, Nix 安装 asmfmt

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

## 安装

```sh
sudo av install brew:asmfmt
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install asmfmt
```

  证据: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install asmfmt
```

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

### Linux

- Nix (92%):

```sh
nix profile install nixpkgs#asmfmt
```

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

## 软件包事实

- **软件包键:** brew:asmfmt
- **软件包管理器:** Homebrew
- **版本:** 1.3.2
- **来源摘要:** Go Assembler Formatter
- **主页:** <https://github.com/klauspost/asmfmt>
- **仓库:** <https://github.com/klauspost/asmfmt>
- **最后更新:** 2026-07-25T14:18:26-04:00
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- asmfmt (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

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

asmfmt is a formatter for Go assembler files. Its README frames the project directly as `gofmt` for assembler code and documents `gofmt`-like flags such as `-d`, `-l`, and `-w`.

### 项目历史

The GitHub repository was created in November 2015, and the first GitHub release, v1.0, was published in April 2016. The README's dated update log records many early formatting fixes around comments, macros, semicolons, and Go assembler syntax.

By the README's own status note, asmfmt is stable and its formatting is expected to change only for bugs. Later releases in 2018, 2019, 2021, and 2022 focused on fixes, module information, and keeping the standalone formatter buildable.

### 采用历史

asmfmt is a niche Go ecosystem tool. It is available through Go install, GitHub releases, Homebrew, MacPorts, and Nix according to the input package facts. Homebrew analytics are small, reflecting that only developers who touch Go assembly files need it.

### 使用方式

The tool is run as `asmfmt [flags] [path ...]` and should be pointed only at assembler files, because the README warns that non-assembler files cannot be positively identified and may be mangled. Editor integration examples include GoLand file watchers and Emacs before-save hooks.

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

asmfmt is package-nerd interesting because it exports the Go ecosystem's formatter culture into the much smaller world of Plan 9 style Go assembly. It is a tiny binary with a stable output contract, exactly the sort of tool package managers like to preserve for reproducible developer workflows.

### 时间线

- 2015: GitHub repository created and early formatting updates logged.
- 2016: v1.0 and v1.1 GitHub releases published.
- 2018: v1.2.0 released.
- 2021: v1.3.x releases refreshed module and comment handling.
- 2022: v1.3.2 released.

### Related projects

- The README positions asmfmt as analogous to gofmt and links Go package documentation on pkg.go.dev.

### 来源

- <https://api.github.com/repos/klauspost/asmfmt>
- <https://api.github.com/repos/klauspost/asmfmt/releases>
- <https://formulae.brew.sh/api/formula/asmfmt.json>
- <https://github.com/klauspost/asmfmt#readme>
- source_facts.package-manager


## 安全说明

narrow executable package without higher-risk signals.

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

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

- Nix - asmfmt: normalized package name match | nixpkgs package indexes: pkgs/by-name/as/asmfmt/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- MacPorts - asmfmt: normalized package name match | MacPorts ports tree: devel/asmfmt/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1


## Combined YAML source

View the package source record on GitHub. [combined/asmfmt.yml](https://github.com/mxcl/pkgdb/blob/main/combined/asmfmt.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
