Shelfbox masa-kjm
winget install --id=MasaKjm.Shelfbox -e Keep local-only files visible in your repository while keeping them out of Git.
winget install --id=MasaKjm.Shelfbox -e Keep local-only files visible in your repository while keeping them out of Git.
Shelfbox keeps personal files—AI agent instructions and skills, notes, scripts, and machine-local configuration—visible in your editor but out of Git. It stores canonical content in a local store and helps restore it after recloning or in a worktree.
AI agent instructions, skills, notes, scripts, and machine-local configuration often need to live inside a repository tree so editors and tools can discover them—but they shouldn't be committed.
Common workarounds have limits:
.gitignore — works for untracked files, but it is shared repository policy rather than a personal local-file mechanism..git/info/exclude — keeps ignore rules local, but only records paths. It does not preserve the files themselves or help restore them after a reclone.Shelfbox manages that lifecycle explicitly: it stores canonical content outside the repository, materializes files at their original paths, keeps them excluded from Git, and can repair or recover that local context across worktrees and after recloning.

# Create a local-only file in your repository
echo "# Local instructions" > AGENTS.local.md
# Confirm it exists and is still untracked
git status --short
# Shelve it (keeps the path visible, stores canonical content outside Git)
shelfbox item add AGENTS.local.md
# The file remains available at its original path
cat AGENTS.local.md
# Confirm Git no longer reports it
git status --short
# Confirm shelfbox is managing it
shelfbox item list --format plain
For an annotated first workflow, see Start Managing a Local File.
For linked Git worktrees, run shelfbox repo repair in the new worktree to restore managed files. See Use a Linked Git Worktree.
For source builds and installation script options, see the installation guide.
To remove shelfbox and optionally clean up its local data, see Uninstallation.
brew install masa-kjm/tap/shelfbox
Download a pre-built binary from GitHub Releases.
The Unix installer uses ~/.local/bin by default.
curl -fsSL https://raw.githubusercontent.com/masa-kjm/shelfbox/main/scripts/install.sh | sh
scoop bucket add masa-kjm https://github.com/masa-kjm/scoop-bucket
scoop install shelfbox
Download a pre-built binary from GitHub Releases.
The PowerShell installer uses $Env:LOCALAPPDATA\Programs\shelfbox\bin by default.
irm https://raw.githubusercontent.com/masa-kjm/shelfbox/main/scripts/install.ps1 | iex
> [!IMPORTANT]
> Windows setup: Before using shelfbox, enable best-effort durability:
>
> powershell > shelfbox config set mutation_durability best-effort >
>
> Windows does not provide the directory-level durability guarantees required by the default require mode.
> Symlink materialization also requires Developer Mode or an elevated shell. If symlinks are unavailable, use copy mode.
With Rust 1.75 or later installed:
cargo install shelfbox --locked
repos/: repo reclaimrepo repair in a newly created worktree: Use a Linked Git Worktreeitem add store rebuild-indexOptional config at ~/.config/shelfbox/config.toml (respects $XDG_CONFIG_HOME):
# store = "/mnt/data/shelfbox-store" # default: ~/.local/share/shelfbox
# default_format = "table" # table | plain | json
# materialization = "symlink" # symlink (default) | copy
# mutation_durability = "require" # require (default) | best-effort
See Config reference for all options and details.
Shelfbox is a single-machine tool. Placing the store on external or network-synced storage is not officially supported — sync conflicts may leave items in an inconsistent state.
Multi-machine sync, secret encryption, and team-shared files are out of scope.
See docs/index.md for the full documentation set.
MIT