Skip to main content

A CLI for managing AI agent config files without committing them to the repo.

Project description

lac

A CLI for managing AI agent config files without committing them to the repo.

  machine A                          machine B
  ─────────                          ─────────
  ~/repo/CLAUDE.md (untracked)       ~/repo/CLAUDE.md (untracked)
        │                                   │
        └─→  lac storage  ←─────────────────┘
              (git push/pull)

Highlights

  • Untracked by design: CLAUDE.md, AGENTS.md, .cursorrules, .mcp.json live in lac storage and are symlinked into each repo. Links are automatically excluded from git.
  • Portable across machines: lac storage is itself a git repo — push it to a private remote, clone elsewhere, and re-register your repos.
  • Per-repo identity: each repo gets its own storage directory, matched by git remote URL or path. The same repo on two machines maps to the same storage.
  • Agent config files: CLAUDE.md / AGENTS.md / .claude/ / .agents/ / .cursorrules / .mcp.json. Add custom files with lac link <name>.

Use cases

AI agent config files (CLAUDE.md, AGENTS.md, .cursorrules, .mcp.json) are sometimes shared, sometimes personal. Open-source projects can't always agree on agent rules; teams under code review may disagree on what belongs in the repo; even on solo repos you might want personal tweaks that don't pollute commits. In all these cases the config stays untracked — and lac keeps the canonical copy in one place that travels with you across machines.

How it works

Lifecycle

$ lac register      → storage directory + metadata (no files touched yet)
$ lac link --all    → agent config files copied to storage
                       symlinks created in the repo
                       auto-excluded from git
$ ... (work)        → edit anywhere — there's only one source
$ lac unregister    → files restored in the repo + storage kept as backup

Agent config files

The set lac knows about by default:

  • CLAUDE.md
  • AGENTS.md
  • .claude/
  • .agents/
  • .cursorrules
  • .mcp.json

Add anything else with lac link <filename>.

Cross-machine sync

lac storage is a git repo. To use the same config on another machine:

# on machine A — initial push
cd "$(lac home)"
git remote add origin <your-private-remote-url>
git add . && git commit -m "initial" && git push -u origin main

# on machine B — clone and reuse
git clone <your-private-remote-url> "$(lac home)"
cd ~/projects/repo
lac register   # matched by git remote URL (or path)
lac link --all

The match between machines happens via the repo's git remote URL when available, or by the repo's path otherwise.

Install

brew install 2ykwang/2ykwang/lac
lac --version
# lac, version 2025.5.15

Quick Start

In any git repo:

cd ~/projects/my-project

lac register
# ✓ registered at /Users/x/.local/share/lac/my-project-abc123
# ℹ run 'lac link' to link agent config files in this repo

lac link --all
# ✓ CLAUDE.md linked
# ✓ AGENTS.md linked
# ✓ .claude linked
# ✓ .agents linked
# ✓ .cursorrules linked
# ✓ .mcp.json linked

Commands

Command What it does
lac register Register the current repo with lac storage.
lac link Interactive checkbox — pick which files to link.
lac link --all Link all agent config files at once.

| lac link <file> | Link a single file by name (custom or known). | | lac status | Show registration state of the current repo. | | lac doctor | Check storage health (broken symlinks, orphaned entries, missing targets). | | lac list | List all registered repos. | | lac unregister | Restore files into the repo and back up the storage. | | lac home | Print the lac storage root. | | lac path [file] | Print storage path for the repo (or a file inside it). | | lac rename <name> | Rename the current repo's storage directory. |

Limits

  • macOS and Linux only. Windows is not supported.
  • Python ≥3.11.
  • Single-user tool. Not designed for team-shared lac storage.
  • Git-tracked files in the repo are skipped during link; lac never overwrites them.
  • Cross-machine sync of lac storage is manual (git push / git pull); lac does not auto-sync.

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

lac_py-2025.5.15.tar.gz (24.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

lac_py-2025.5.15-py3-none-any.whl (19.7 kB view details)

Uploaded Python 3

File details

Details for the file lac_py-2025.5.15.tar.gz.

File metadata

  • Download URL: lac_py-2025.5.15.tar.gz
  • Upload date:
  • Size: 24.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.13 {"installer":{"name":"uv","version":"0.11.13","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for lac_py-2025.5.15.tar.gz
Algorithm Hash digest
SHA256 a8809a699f986de72854f74af794a153eb2e22a89fbd721d082cdfa6af775d51
MD5 b91ba0a6bd63dbd33cb84db6b0b1c864
BLAKE2b-256 1ce3ca57a95ebfc89a5c6650c2e936e7c4fec49776a45a2e726faffb4227d239

See more details on using hashes here.

File details

Details for the file lac_py-2025.5.15-py3-none-any.whl.

File metadata

  • Download URL: lac_py-2025.5.15-py3-none-any.whl
  • Upload date:
  • Size: 19.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.13 {"installer":{"name":"uv","version":"0.11.13","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for lac_py-2025.5.15-py3-none-any.whl
Algorithm Hash digest
SHA256 53c1058724ec28ac052cc5c78b960237add6d260f023f692c41857633605576b
MD5 73146ac42351b8ca24696e7219cb144a
BLAKE2b-256 1e8f192530f6b5e8ba811311ef62a4ae8c42a3c06e828486e5b8c6506e93c71a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page