# 使用 Homebrew, chocolatey, MacPorts, Nix 安装 pmd

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

## 安装

```sh
sudo av install brew:pmd
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install pmd
```

  证据: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install pmd
```

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

### Linux

- Nix (92%):

```sh
nix profile install nixpkgs#pmd
```

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

### Windows

- Chocolatey (92%):

```sh
choco install pmd
```

  证据: Chocolatey community package catalog: pmd from http://community.chocolatey.org/api/v2/Packages?$filter=IsLatestVersion&$select=Id&$top=1000&$skiptoken='11','pester'

## 软件包事实

- **软件包键:** brew:pmd
- **软件包管理器:** Homebrew
- **版本:** 7.26.0
- **来源摘要:** Source code analyzer for Java, JavaScript, and more
- **主页:** <https://pmd.github.io>
- **仓库:** <https://github.com/pmd/pmd>
- **最后更新:** 2026-06-29T11:30:12Z
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- pmd (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

- 页面生成时间: 2026-08-03
- 管理器版本: 7.26.0

## 安全说明

narrow executable package without higher-risk signals.

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

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

- Nix - pmd: normalized package name match | nixpkgs package indexes: pkgs/by-name/pm/pmd/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- MacPorts - pmd: normalized package name match | MacPorts ports tree: java/pmd/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1
- Chocolatey - pmd: normalized package name match | Chocolatey community package catalog: pmd from http://community.chocolatey.org/api/v2/Packages?$filter=IsLatestVersion&$select=Id&$top=1000&$skiptoken='11','pester'


## Combined YAML source

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


## 来源

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