# 使用 Homebrew, apt, zypper 安装 modules

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

## 安装

```sh
sudo av install brew:modules
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install modules
```

  证据: local Homebrew formula metadata

### Linux

- Debian apt (92%):

```sh
sudo apt install environment-modules
```

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

- zypper (92%):

```sh
sudo zypper install Modules
```

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

## 软件包事实

- **软件包键:** brew:modules
- **软件包管理器:** Homebrew
- **软件包管理器页面:** <https://formulae.brew.sh/formula/modules>
- **版本:** 5.6.1
- **来源摘要:** Dynamic modification of a user's environment via modulefiles
- **主页:** <https://modules.sourceforge.net/>
- **仓库:** <https://github.com/envmodules/modules>
- **上游文档:** <https://github.com/envmodules/modules#readme>
- **许可证:** GPL-2.0-or-later
- **源码归档:** <https://downloads.sourceforge.net/project/modules/Modules/modules-5.6.1/modules-5.6.1.tar.bz2>
- **最后更新:** 2026-06-22T14:05:31-07:00
- **已生成:** 2026-07-09T07:20:21+00:00

## 可执行文件

- add.modules (cli)
- envml (cli)
- mkroot (cli)
- modulecmd (cli)
- add.modules (别名)
- envml (别名)
- mkroot (别名)
- modulecmd (别名)

## 依赖

- tcl-tk

## macOS 提供的库

- less

## 安装行为

- post-install 钩子: 未定义
- 注意事项: To activate modules, add the following at the end of your .zshrc: source $HOMEBREW_PREFIX/opt/modules/init/zsh You will also need to restart your terminal for this change to take effect.
- Bottle: 可用 于 arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sonoma, x86_64_linux

## 版本和新鲜度

- 页面生成时间: 2026-07-09
- 管理器版本: 5.6.1
- 管理器更新时间: 2026-06-22
- 本地数据: OK
- 上游仓库: https://modules.sourceforge.net/
- 信息: Release/tag comparison is only available for GitHub repositories.
## 项目历史与用法

Environment Modules began in 1991 with John L. Furlani's paper "Modules: Providing a Flexible User Environment," written at Sun Microsystems to solve a practical Unix administration problem: users and admins needed a cleaner way to add, remove, and switch application-specific environment settings without constantly editing shell startup files. The original design wrapped environment changes into named modulefiles and exposed them through a single module command, so software setup could be loaded, unloaded, or swapped during a shell session.

### 项目历史

The project moved through several implementations. Project history presented by the Environment Modules maintainers describes versions 1 and 2 under Furlani, version 3.0 under Peter W. Osel and Jens Hamisch, the Linux/GPL 3.1 and 3.2 line under R.K. Owen at NERSC, and the pure Tcl modulecmd.tcl work by Mark Lakata and Kent Mein. Xavier Delaruelle at CEA became project leader in 2017 and led the version 4 and version 5 line based on the Tcl implementation.

### 采用历史

Its role is strongest in high-performance computing and multi-user Unix environments. Modulefiles let sites publish many versions of compilers, MPI stacks, libraries, tools, and data endpoints while users keep a consistent command interface across shells. The project documentation shows typical use through commands such as module load, module switch, and module unload, and the HPSF announcement describes the module command as a familiar interface for supercomputer users accessing a software catalog.

### 使用方式

Environment Modules shares its niche with Lmod, the Lua-based module implementation that became especially prominent while Environment Modules development was on hiatus. The revived Tcl-based project added collections, dependency handling, advanced version specifiers, module variants, Lmod Tcl modulefile compatibility, Windows shell support, linting, logging, and cache support. In 2025, Modules moved under the High Performance Software Foundation within the Linux Foundation, giving the long-running HPC environment tool a formal neutral governance home.

### 来源

- <https://envmodules.io/>
- <https://envmodules.io/docs/Modules-Paper.pdf>
- <https://envmodules.io/docs/modules_eum25.pdf>
- <https://github.com/envmodules/modules>
- <https://hpsf.io/blog/2025/high-performance-software-foundation-welcomes-modules-as-hpsf-project/>
- <https://modules.readthedocs.io/en/v5.1.1/>


## 安全说明

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: /etc/environment-modules/initrc, /etc/environment-modules/modulespath, /etc/environment-modules/siteconfig.tcl, /etc/environment-modules/rc, ~/.modulerc, <modulepath>/.modulerc
## 源数据库详情

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** modules
- **Version Scheme:** 0
- **Revision:** 0
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** stable

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

- Debian apt - environment-modules - 5.5.0-1: normalized package name match | Debian stable package indexes: environment-modules from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Modular system for handling environment variables | http://modules.sourceforge.net/
- Ubuntu apt - environment-modules - 5.4.0-1: normalized package name match | Ubuntu 24.04 LTS package indexes: environment-modules from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Modular system for handling environment variables | http://modules.sourceforge.net/
- zypper - Modules - 4.8.0-4.4: normalized package name match | openSUSE Tumbleweed package metadata: Modules from https://download.opensuse.org/tumbleweed/repo/oss/repodata/be8d3611d25469107f32075a1697e69ec57a2b850b42348a658cc671ad5ec2b50760d02c3e59524d50da9a11d5be799bdaffba2e166e8ca8858512e3c0bd665d-primary.xml.zst | Change environment at runtime | http://modules.sourceforge.net/
- zypper - Modules-doc - 4.8.0-4.4: normalized package name match | openSUSE Tumbleweed package metadata: Modules-doc from https://download.opensuse.org/tumbleweed/repo/oss/repodata/be8d3611d25469107f32075a1697e69ec57a2b850b42348a658cc671ad5ec2b50760d02c3e59524d50da9a11d5be799bdaffba2e166e8ca8858512e3c0bd665d-primary.xml.zst | Documentation for Environment Modules | http://modules.sourceforge.net/


## 相关链接

- [Terminal utility packages](https://www.automicvault.com/zh-hans/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Text processing packages](https://www.automicvault.com/zh-hans/pkg/text-processing-tools/) - Matched text, document, or structured-data processing metadata.
- [Developer build packages](https://www.automicvault.com/zh-hans/pkg/developer-build-tools/) - Matched build, compiler, generator, or developer workflow metadata.
- [Networking and protocol packages](https://www.automicvault.com/zh-hans/pkg/networking-protocol-tools/) - Matched network, protocol, or remote-service metadata.
- [tcl-tk](https://www.automicvault.com/zh-hans/pkg/brew/tcl-tk/) - Runtime dependency declared by Homebrew.
- [direnv](https://www.automicvault.com/zh-hans/pkg/brew/direnv/) - Shares av.db curated category or tags: cli, developer-tools, environment-management, shell.
- [shadowenv](https://www.automicvault.com/zh-hans/pkg/brew/shadowenv/) - Shares av.db curated category or tags: cli, developer-tools, environment-management, shell.
- [virtualenvwrapper](https://www.automicvault.com/zh-hans/pkg/brew/virtualenvwrapper/) - Shares av.db curated category or tags: cli, developer-tools, environment-management, shell.
- [fades](https://www.automicvault.com/zh-hans/pkg/brew/fades/) - Shares av.db curated category or tags: cli, developer-tools, environment-management.
- [hermit](https://www.automicvault.com/zh-hans/pkg/brew/hermit/) - Shares av.db curated category or tags: cli, developer-tools, environment-management.
- [pyenv-pip-migrate](https://www.automicvault.com/zh-hans/pkg/brew/pyenv-pip-migrate/) - Shares av.db curated category or tags: cli, developer-tools, environment-management.
- [pyenv-virtualenv](https://www.automicvault.com/zh-hans/pkg/brew/pyenv-virtualenv/) - Shares av.db curated category or tags: cli, developer-tools, environment-management.
- [pyenv-virtualenvwrapper](https://www.automicvault.com/zh-hans/pkg/brew/pyenv-virtualenvwrapper/) - Shares av.db curated category or tags: cli, developer-tools, environment-management.

## Combined YAML source

View the package source record on GitHub. [combined/modules.yml](https://github.com/automic-vault/db/blob/main/combined/modules.yml)


## 来源

- Nucleus package database
- Geiger risk classifier
- package-page enrichment
- curated configuration and credential file locations
- curated package history
- package version freshness
- av.db category and tag curation
- package relationship graph
- external package-manager database matches
- cross-ecosystem install command graph
