macOS
brew install gnu-complexitylocal Homebrew formula metadata
安装
brew install gnu-complexitylocal Homebrew formula metadata
sudo apt install complexityDebian stable package indexes · complexity · 来源: deb.debian.org
nix profile install nixpkgs#complexitynixpkgs package indexes · pkgs/by-name/co/complexity/package.nix · 来源: api.github.com
sudo zypper install complexityopenSUSE Tumbleweed package metadata · complexity · 来源: download.opensuse.org
概览
Measures complexity of C source
历史
GNU Complexity is a small GNU static-analysis tool for measuring the complexity of C functions, designed as a more human-comprehension-oriented alternative to simple McCabe-style path counts.
The GNU Complexity manual documents version 0.4 as of May 2011 and describes a tool by Bruce Korb for analyzing C function complexity. Its rationale is explicit: McCabe-style scoring and `pmccabe` are useful for testing effort, but GNU Complexity tries to better rank functions that are difficult for humans to understand by considering length, nesting, switch bodies, and complicated boolean expressions.
GNU Complexity has a narrow adoption footprint compared with larger GNU developer tools. Its significance is in the code-review and maintenance niche: it gives C maintainers a command-line metric that can point to suspicious functions in unfamiliar code, estimate testing or comprehension effort, and produce sorted score tables and histograms.
Practitioners run `complexity` over C source files to report procedure scores, line counts, source locations, and optional histograms. The manual's example runs the tool against its own source with a low threshold, illustrating use as a quick audit tool for ranking functions before refactoring or review.
For package nerds, GNU Complexity is interesting because it embodies a Unix-tool approach to maintainability: one command, text output, tunable thresholds, and a documented scoring model. It is useful in distributions as a lightweight companion to older tools such as `pmccabe` rather than as a large static-analysis framework.
安全态势
narrow executable package without higher-risk signals.
绿色 风险 · 低 置信度 · appliance
在无人值守的代理使用前,请检查该工具是否读取明文凭据、写入远程状态、发布制品或调用插件。
可执行文件
| 命令 | 类型 | 暴露范围 | 备注 |
|---|---|---|---|
complexity | cli | 全局可执行文件 | |
cx-vs-mc | cli | 全局可执行文件 |
新鲜度
这些信号区分页生成时间、软件包管理器活动和上游发布比较。只有存在证据 URL 和可比较版本时,才会提示版本落后。
https://www.gnu.org/software/complexity/
安装元数据
| 软件包键 | brew:gnu-complexity |
|---|---|
| 版本 | 1.13 |
| 软件包管理器 | Homebrew |
| 软件包管理器页面 | https://formulae.brew.sh/formula/gnu-complexity |
| 主页 | https://www.gnu.org/software/complexity/ |
| 仓库 | https://git.savannah.gnu.org/cgit/complexity.git |
| 上游文档 | https://www.gnu.org/software/complexity/manual |
| 许可证 | GPL-3.0-or-later |
| 源码归档 | https://ftpmirror.gnu.org/gnu/complexity/complexity-1.13.tar.xz |
| 依赖 | autogen |
| 构建依赖 | autoconf, automake |
| Bottle | 可用 (于 arm64_big_sur, arm64_linux, arm64_monterey, arm64_sequoia, arm64_sonoma, arm64_tahoe, arm64_ventura, big_sur, monterey, sonoma, ventura, x86_64_linux) |
| Homebrew post-install | 未定义 |
| 服务 | 未声明 |
注册表事实
| Source Database | Homebrew formula API |
|---|---|
| Tap | homebrew/core |
| Full Name | gnu-complexity |
| Version Scheme | 0 |
| Revision | 0 |
| Bottle Stable Root URL | https://ghcr.io/v2/homebrew/core |
| Deprecated | no |
| Disabled | no |
| Keg Only | no |
| URL Keys |
|
源数据库匹配
匹配项来自外部软件包管理器索引,并与本地 Automic Vault 软件包链接分开显示。
complexity 1.13-1+b1
tool for analyzing the complexity of C program functions
https://gnu.org/software/complexity
sudo apt install complexitycomplexity-doc 1.13-1
tool for analyzing the complexity of C program (documentation)
https://gnu.org/software/complexity
sudo apt install complexity-doccomplexity
nix profile install nixpkgs#complexitycomplexity 1.13-1
tool for analyzing the complexity of C program functions
https://gnu.org/software/complexity
sudo apt install complexitycomplexity-doc 1.13-1
tool for analyzing the complexity of C program (documentation)
https://gnu.org/software/complexity
sudo apt install complexity-doccomplexity 1.13-1.7
C source code complexity computation utility
https://www.gnu.org/software/complexity/
sudo zypper install complexity来源线索
此页面由 av-web 从 scripts/generate-pkg-sqlite.py 生成的私有软件包 SQLite 工件提供。
View the package source record on GitHub.