lean-setup

Configure Lean 4 toolchain PATH for terminals and tasks.

Updated Mar 16, 2026
One-click install
npx skills add https://github.com/my04337/shapez2-in-lean --skill lean-setup
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: lean-setup
Source: https://github.com/my04337/shapez2-in-lean/tree/main/.github/skills/lean-setup
Command: npx skills add https://github.com/my04337/shapez2-in-lean --skill lean-setup

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

Resolve Lean 4 toolchain PATH issues by configuring elan/lake/lean commands in the terminal.

Core Features & Use Cases

  • Detects missing lean or lake commands and provides PATH setup guidance.
  • Provides OS-specific setup scripts for Windows and macOS/Linux, plus VS Code PATH integration.
  • Includes troubleshooting tips to verify installation and environment configuration.

Quick Start

Run the appropriate setup script to add Lean's PATH to your shell and verify lean --version.

Frequently Asked Questions about lean-setup

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I fix the 'lean' or 'lake' command not found error in my terminal?

To fix the 'lean' or 'lake' command not found error, you must configure the Lean 4 toolchain PATH in your shell. This setup process detects missing commands and applies PATH augmentation so your terminal can resolve elan, lake, and lean executables correctly.

What is the best way to set up the Lean 4 toolchain PATH on Windows and macOS?

The best way to set up the Lean 4 toolchain PATH is by running OS-specific setup scripts provided for Windows and macOS/Linux. These scripts automatically apply the necessary environment configuration and integrate the toolchain directly into your shell.

Does VS Code need manual PATH integration to run Lean 4 tasks?

VS Code requires proper PATH integration to run Lean 4 tasks and resolve toolchain commands. The setup provides specific guidance to augment the PATH environment, ensuring the editor can successfully locate and execute lean and lake commands.

Why is my Lean toolchain not recognized even after installation?

Your Lean toolchain might not be recognized because the shell PATH lacks the correct elan directory entries. Troubleshooting this involves running script-based verification steps to ensure the environment configuration properly points to the installed toolchain binaries.

Can I verify my Lean 4 environment configuration with a single command?

You can verify your Lean 4 environment configuration by running the `lean --version` command after executing the setup scripts. This checks that your terminal successfully resolves the toolchain and confirms the PATH augmentation is working.