# 使用 Homebrew, apk, apt, dnf, MacPorts, Nix, pacman, zypper, scoop 安装 cscope

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

## 安装

```sh
sudo av install brew:cscope
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install cscope
```

  证据: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install cscope
```

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

### Linux

- apk (92%):

```sh
sudo apk add cscope
```

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

- Debian apt (92%):

```sh
sudo apt install cscope
```

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

- dnf (92%):

```sh
sudo dnf install cscope
```

  证据: Fedora Rawhide package metadata: cscope 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#cscope
```

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

- pacman (92%):

```sh
sudo pacman -S cscope
```

  证据: Arch Linux sync databases: cscope from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz

- zypper (92%):

```sh
sudo zypper install cscope
```

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

### Windows

- Scoop (92%):

```sh
scoop install main/cscope
```

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

## 软件包事实

- **软件包键:** brew:cscope
- **软件包管理器:** Homebrew
- **版本:** 15.9
- **来源摘要:** Tool for browsing source code
- **主页:** <https://cscope.sourceforge.net/>
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- cscope (别名)
- ocs (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

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

cscope is a classic Unix source-code browser and cross-reference tool for C-family code. Its history is unusually important for package nerds because it moved from Bell Labs internal tooling into official AT&T Unix and then into open-source Unix distributions.

### 项目历史

The official cscope history page attributes the original work to Joe Steffen at Bell Labs in the early 1980s. It describes the first version as growing from shell scripts using grep and sed into a C program that parsed source into a tagged, updateable database for repeated searches.

### 采用历史

The cscope homepage says it was part of the official AT&T Unix distribution for many years. The history page says it spread through AT&T and Bell Labs by the exptools network, was used at AT&T locations around the world, and supported projects with millions of lines of C and C++.

### 使用方式

The man page describes cscope as an interactive, screen-oriented tool that builds a cscope.out cross-reference database and searches definitions, callers, callees, strings, regular expressions, files, and includes. It can also use cscope.files as the default namefile and offers a line-oriented mode for scripts and editor frontends.

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

cscope is a small but culturally durable Unix developer tool: curses UI, on-disk indexes, editor integration, and broad packaging across Homebrew, Linux distributions, MacPorts, Nix, Scoop, and others. It is the kind of tool whose package value is stable because it serves old and large codebases without needing a language server.

### 时间线

- Early 1980s: Joe Steffen started cscope at Bell Labs.
- AT&T Unix era: cscope became part of the official AT&T Unix distribution.
- 2000: SCO open sourced the Cscope code under the BSD license.
- 2012: The official homepage announced cscope 15.8a.
- 2026: Homebrew formula metadata lists stable version 15.9.

### Related projects

- The homepage documents integration with Vim and nvi, and the man page documents command-line and line-oriented modes that allow wrappers and frontends.

### 来源

- <https://cscope.sourceforge.net/>
- <https://cscope.sourceforge.net/history.html>
- <https://cscope.sourceforge.net/cscope_man_page.html>
- <https://formulae.brew.sh/formula/cscope>


## 安全说明

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: ./cscope.files
## 其他软件包管理器记录

- Debian apt - cscope - 15.9-2: normalized package name match | Debian stable package indexes: cscope from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | interactively examine a C program source | https://cscope.sourceforge.net/
- Nix - cscope: normalized package name match | nixpkgs package indexes: pkgs/by-name/cs/cscope/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - cscope - 15.9-2: normalized package name match | Ubuntu 24.04 LTS package indexes: cscope from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | interactively examine a C program source | https://cscope.sourceforge.net/
- apk - cscope - 15.9-r1: normalized package name match | Alpine Linux edge package indexes: cscope from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz | Cscope is a developer's tool for browsing source code. | https://cscope.sourceforge.net/
- apk - cscope-doc - 15.9-r1: normalized package name match | Alpine Linux edge package indexes: cscope-doc from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz | Cscope is a developer's tool for browsing source code. (documentation) | https://cscope.sourceforge.net/
- dnf - cscope - 15.9-32.fc45: normalized package name match | Fedora Rawhide package metadata: cscope from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst | C source code tree search and browse tool | http://cscope.sourceforge.net
- pacman - cscope - 15.9-3: normalized package name match | Arch Linux sync databases: cscope from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz | A developers tool for browsing program code | http://cscope.sourceforge.net/
- zypper - cscope - 15.9-2.8: normalized package name match | openSUSE Tumbleweed package metadata: cscope from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst | Interactive Tool for Browsing C Source Code | http://cscope.sourceforge.net/
- MacPorts - cscope: normalized package name match | MacPorts ports tree: devel/cscope/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1
- Scoop - main/cscope: normalized package name match | Scoop official bucket manifest trees: bucket/cscope.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/cscope.yml](https://github.com/mxcl/pkgdb/blob/main/combined/cscope.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
