# Multi Repo Stale Lock Recovery

> Diagnose and recover from stale git lock files in multi-repo workspaces, especially with submodules

- Skill: `vamseeachanta/multi-repo-stale-lock-recovery` (Agent Skill)
- Install (CLI): `npx skillmds@latest add vamseeachanta/multi-repo-stale-lock-recovery`
- Raw SKILL.md: https://api.skillmd.com/api/skills/vamseeachanta/multi-repo-stale-lock-recovery/raw
- Safety review: PASS (external: skill-scanner PASS, skillspector PASS)
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- Author: vamseeachanta (https://skillmd.com/u/vamseeachanta)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/vamseeachanta/multi-repo-stale-lock-recovery

---


# Multi-Repo Stale Lock Recovery

When bulk operations fail across multiple repos with `.git/index.lock` errors, check for stale crashes from background processes (especially with submodules). Use `lsof` to verify no git process is actually running, then safely remove the lock file and retry. If the lock reappears immediately after cleanup, a background process may still be running — wait briefly and monitor with `ps` before retrying. In submodule-heavy workspaces, lock files in one repo can reference another's submodule path.
