lean-upgrade
Use when a Lean or Mathlib version change is requested or an explicitly requested upgrade causes compatibility failures.
- License 许可
- GPL-3.0
- 最近更新
- 2026-11-13
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- lean-upgrade
- description
- Use when a Lean or Mathlib version change is requested or an explicitly requested upgrade causes compatibility failures.
03 SKILL.md 正文
Migrate a pinned Lean environment
Input: requested target revision, current workspace and authorized scope. Output: new coherent pins, repaired source and before/after verification.
Run lean-doctor and record the current toolchain, manifests, dirty files and
build evidence. Resolve the requested revision concretely; “latest” requires a
current lookup and recording the resulting commit. Do not upgrade as an
incidental response to a proof failure.
Preserve an owned baseline. Select the matching Lean version from the target
dependency, update the intended lakefile/lockfile using that project's supported
commands, and fetch available compatible caches. Diagnose API changes from
actual errors and upstream definitions with lean-diagnose/lean-search.
Repair incrementally without weakening theorem statements or changing source
meaning merely to compile.
Build all selected modules and affected consumers. Run lean-verify and fresh
lean-fidelity where definitions or semantics changed. Mark prior receipts
stale. If migration fails, report exact blockers and restore only owned edits
when restoration is requested or necessary; never reset unrelated work.
Example: a renamed library lemma needs checked replacement and callers, while a changed mathematical definition may require a separate correspondence decision.
04 同仓库更多 Skills
writing-skills
Use when creating new skills, editing existing skills, or verifying skills work before deployment
writing-plans
Use when you have a spec or requirements for a multi-step task, before touching code
verification-before-completion
Use when about to claim work is complete, fixed, or passing, before committing or creating PRs - requires running verification commands and confirming output before making any success claims; evidence before assertions always
using-superpowers
Use when starting any conversation - establishes how to find and use skills, requiring skill invocation before ANY response including clarifying questions
using-git-worktrees
Use when starting feature work that needs isolation from current workspace or before executing implementation plans - ensures an isolated workspace exists via native tools or git worktree fallback
test-driven-development
Use when implementing any feature or bugfix, before writing implementation code