# 使用 Homebrew, Nix 安装 erg

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

## 安装

```sh
sudo av install brew:erg
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install erg
```

  证据: local Homebrew formula metadata

### Linux

- Nix (92%):

```sh
nix profile install nixpkgs#erg
```

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

## 软件包事实

- **软件包键:** brew:erg
- **软件包管理器:** Homebrew
- **版本:** 0.6.53
- **来源摘要:** Statically typed language that can deeply improve the Python ecosystem
- **主页:** <https://github.com/erg-lang/erg>
- **仓库:** <https://github.com/erg-lang/erg>
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- erg (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

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

Erg is an experimental statically typed programming language implemented in Rust and designed to interoperate with Python. The official README presents it as a language for Python users who want stronger static guarantees, readable errors, and a practical mix of functional and object-oriented programming.

### 项目历史

The public GitHub repository was created in 2022, with an initial 0.1.1 GitHub release shortly afterward. The README states that the repository contains the compiler and documentation and lists features such as refinement-style type checks, Python API imports, optional language-server builds, and localized diagnostics.

### 采用历史

Erg's adoption is early-stage and developer-experimental. The README points users to Cargo, source builds, Nix, a web playground, and multilingual documentation, while the supplied input lists Homebrew and Nix package availability.

### 使用方式

Users run the `erg` compiler or REPL, build it with Cargo or Nix, and can enable feature flags such as language-specific diagnostics, the Erg Language Server, debug mode, or richer REPL behavior. Its core usage story is trying a Python-compatible language with static checks rather than replacing the Python runtime outright.

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

Erg is interesting to package nerds as a young language-runtime formula: it mixes a Rust compiler, Python runtime requirements, optional language-server pieces, and docs/playground expectations. Its package-manager presence is more about discoverability for language experimenters than mass production use.

### 时间线

- 2022: The GitHub repository was created.
- 2022: Version 0.1.1 was published on GitHub releases.
- 2020s: The README documents Cargo, source, Nix, and optional ELS installation paths.

### Related projects

- Erg is related to Python, Rust, Nix, Cargo, and editor language-server tooling.

### 来源

- <https://github.com/erg-lang/erg>
- <https://github.com/erg-lang/erg/releases>
- <https://api.github.com/repos/erg-lang/erg>
- <https://erg-lang.org/the-erg-book>


## 安全说明

narrow executable package without higher-risk signals.

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

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

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


## Combined YAML source

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