# elan-init を Homebrew, apt, Nix, scoop, winget, MacPorts でインストール

elan-init のインストール経路、実行ファイル、メタデータ、AI エージェント向けセキュリティノートを確認します。

## インストール

```sh
sudo av install brew:elan-init
```

追加のインストールコマンド:

### macOS

- Homebrew (100%):

```sh
brew install elan-init
```

  証拠: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install lean
```

  証拠: MacPorts ports tree: math/lean/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1

### Linux

- Debian apt (92%):

```sh
sudo apt install elan
```

  証拠: Debian stable package indexes: elan from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz

- Nix (92%):

```sh
nix profile install nixpkgs#elan
```

  証拠: nixpkgs package indexes: pkgs/by-name/el/elan/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

### Windows

- Scoop (92%):

```sh
scoop install main/elan
```

  証拠: Scoop official bucket manifest trees: bucket/elan.json from https://api.github.com/repos/ScoopInstaller/Main/git/trees/master?recursive=1

- winget (92%):

```sh
winget install --id Lean.Elan -e
```

  証拠: Windows Package Manager source index: Lean.Elan from https://cdn.winget.microsoft.com/cache/source.msix

## パッケージ情報

- **パッケージキー:** brew:elan-init
- **パッケージマネージャ:** Homebrew
- **バージョン:** 4.2.3
- **ソース概要:** Lean Theorem Prover installer and version manager
- **ホームページ:** <https://github.com/leanprover/elan>
- **リポジトリ:** <https://github.com/leanprover/elan>
- **最終更新:** 2026-06-13T01:24:10+02:00
- **生成日時:** 2026-08-03T19:37:03+00:00

## 実行可能ファイル

- elan (エイリアス)
- elan-init (エイリアス)
- lake (エイリアス)
- lean (エイリアス)
- leanc (エイリアス)
- leanchecker (エイリアス)
- leanmake (エイリアス)
- leanpkg (エイリアス)

## インストール挙動

- Bottle: 利用不可

## バージョンと鮮度

- ページ生成日: 2026-08-03
- マネージャ版: 4.2.3
## プロジェクトの歴史と使われ方

elan is the Lean theorem prover toolchain manager. It installs Lean toolchains and places proxy binaries such as `lean`, `lake`, and `elan` on PATH so a project can select the compiler version declared in its `lean-toolchain` file.

### プロジェクトの歴史

The elan repository was created in April 2018 as Lean's answer to language-specific version managers. Its README explicitly describes the implementation as a fork of rustup, adapted from Rust's toolchain model to Lean's compiler, package manager, and release infrastructure.

The design followed Lean's project-local workflow: a repository can commit a `lean-toolchain` file, and elan will automatically select and download the required Lean version when `lean` or `lake` is invoked.

### 採用の歴史

elan became central to modern Lean usage because Lean projects often depend on precise compiler versions, especially around Lean 4 nightly and stable releases. The Lean reference manual documents elan as the standard way to manage installed toolchains, select defaults, and override versions per project.

Its package adoption is practical rather than flashy: package managers distribute `elan-init`, while the installed proxies expose Lean, Lake, and related tools under their usual command names.

### 使われ方

Typical usage starts with the `elan-init` installer, which installs into `~/.elan` by default and can update shell startup files. After installation, `elan show`, `elan default`, and project-local `lean-toolchain` files control which Lean version is active.

For package maintainers, elan matters because a single package can provide a family of executables while deferring the actual Lean compiler download until a project requests a specific toolchain.

### パッケージ好きにとっての重要性

elan is a clean example of the rustup pattern spreading to another language ecosystem: a tiny manager package, shim executables, per-project version files, and lazy toolchain installation. That makes it especially interesting in package-manager databases because the package name `elan-init` is only the installer face of a larger language runtime workflow.

### タイムライン

- 2018: GitHub repository created for the Lean toolchain manager.
- 2023: README examples show Lean 4 nightly toolchains selected by `lean-toolchain`.
- 2025: v4.0.0 released for the Lean 4 era.
- 2026: v4.2.x releases continue active maintenance.

### Related projects

- elan is closely related to Lean, Lake, leanpkg, and rustup. Its model also resembles ghcup, pyenv, nvm, and other language version managers, but it is tightly integrated with Lean's official toolchain naming.

### ソース

- <https://github.com/leanprover/elan>
- <https://raw.githubusercontent.com/leanprover/elan/master/README.md>
- <https://lean-lang.org/doc/reference/latest/Build-Tools-and-Distribution/Managing-Toolchains-with-Elan>
- <https://api.github.com/repos/leanprover/elan>
- <https://api.github.com/repos/leanprover/elan/releases>


## セキュリティノート

infrastructure mutation or orchestration signal.

- **Geiger リスク:** orange / 中
- infrastructure mutation or orchestration signal


## 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: lean-toolchain
## 他のパッケージマネージャ記録

- MacPorts - lean: installed executable or alias match | MacPorts ports tree: math/lean/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1
- Debian apt - elan - 3.1.1-6: installed executable or alias match | Debian stable package indexes: elan from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | tool for managing installations of the Lean theorem prover | https://github.com/leanprover/elan
- Nix - elan: installed executable or alias match | nixpkgs package indexes: pkgs/by-name/el/elan/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Nix - lean: installed executable or alias match | nixpkgs package indexes: pkgs/by-name/le/lean/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - elan - 3.1.0-1build2: installed executable or alias match | Ubuntu 24.04 LTS package indexes: elan from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | tool for managing installations of the Lean theorem prover | https://github.com/leanprover/elan
- Scoop - main/elan: installed executable or alias match | Scoop official bucket manifest trees: bucket/elan.json from https://api.github.com/repos/ScoopInstaller/Main/git/trees/master?recursive=1
- winget - Lean.Elan: installed executable or alias match | Windows Package Manager source index: Lean.Elan from https://cdn.winget.microsoft.com/cache/source.msix
- winget - Lean.Lean: installed executable or alias match | Windows Package Manager source index: Lean.Lean from https://cdn.winget.microsoft.com/cache/source.msix
- winget - MPI.ELAN: installed executable or alias match | Windows Package Manager source index: MPI.ELAN from https://cdn.winget.microsoft.com/cache/source.msix


## Combined YAML source

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