{"_id":"@avelor/bonsai","name":"@avelor/bonsai","dist-tags":{"latest":"0.1.0"},"versions":{"0.1.0":{"name":"@avelor/bonsai","version":"0.1.0","description":"Git worktree manager. Branch-centric, zero configuration.","keywords":["git","worktree","branch","workflow","developer-tools"],"license":"MIT","author":{"name":"Avelor","email":"cruz@avelor.es"},"repository":{"type":"git","url":"git+https://github.com/avelor-es/bonsai.git"},"publishConfig":{"access":"public"},"type":"module","bin":{"bonsai":"bin/bonsai.js"},"scripts":{"test":"node --test test/*.test.js","prepublishOnly":"node --test test/*.test.js"},"engines":{"node":">=18"},"_id":"@avelor/bonsai@0.1.0","bugs":{"url":"https://github.com/avelor-es/bonsai/issues"},"homepage":"https://github.com/avelor-es/bonsai#readme","_nodeVersion":"24.13.0","_npmVersion":"11.6.2","dist":{"integrity":"sha512-HefEpLAj8Qx/PkJ64SJUBiA45F1aur/5GDs/xqw/4J9KfXSBVU7c70s7dk+qr9VnKETpkhnG+ZU8saBQMB3rlQ==","shasum":"7b885dd1f479c9bc21199d5fee8d9342c28ab1ce","tarball":"https://registry.npmjs.org/@avelor/bonsai/-/bonsai-0.1.0.tgz","fileCount":9,"unpackedSize":16947,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIAO01iIzOOUzUyg4n5XOtHyxnEPrXPe6Z0A4e+PFoBx0AiAq+cutDpyEm1NPdtS3ZYELa0BjvLMLnDYluzgjIgA+gg=="}]},"_npmUser":{"name":"christianecg","email":"contacto@christianecg.com"},"directories":{},"maintainers":[{"name":"christianecg","email":"contacto@christianecg.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/bonsai_0.1.0_1780496295567_0.8165437912541795"},"_hasShrinkwrap":false}},"time":{"created":"2026-06-03T14:18:15.453Z","0.1.0":"2026-06-03T14:18:15.719Z","modified":"2026-06-03T14:18:15.946Z"},"maintainers":[{"name":"christianecg","email":"contacto@christianecg.com"}],"description":"Git worktree manager. Branch-centric, zero configuration.","homepage":"https://github.com/avelor-es/bonsai#readme","keywords":["git","worktree","branch","workflow","developer-tools"],"repository":{"type":"git","url":"git+https://github.com/avelor-es/bonsai.git"},"author":{"name":"Avelor","email":"cruz@avelor.es"},"bugs":{"url":"https://github.com/avelor-es/bonsai/issues"},"license":"MIT","readme":"# @avelor/bonsai\n\nGit worktree manager. Branch-centric, zero configuration.\n\n![demo](demo.gif)\n\n## Install\n\n```sh\nnpm install -g @avelor/bonsai\nbonsai install\n```\n\n## Why\n\nGit worktrees let you work on multiple branches simultaneously in separate directories — no stashing, no context switching. They're one of git's most underused features because the syntax is too hard to remember:\n\n```sh\n# raw git — you have to know the target path, the branch name, and the right flags\ngit worktree add ../myrepo-feature-auth feature/auth\n\n# bonsai\nbonsai feature/auth\n```\n\nBonsai fixes that with a branch-centric interface. Just name the branch — bonsai figures out whether to create it, track it from remote, or open an existing worktree. Worktrees always live in `.bonsai/` inside your repo.\n\n## Setup\n\nRun once after install:\n\n```sh\nbonsai install\nsource ~/.zshrc   # or: source ~/.bashrc\n```\n\nThis installs a shell function that enables automatic `cd` when opening worktrees.\n\n## Usage\n\n```sh\nbonsai feature/auth      # open worktree — creates it if needed\nbonsai                   # list all worktrees\nbonsai rm feature/auth   # remove a worktree\nbonsai prune             # remove merged worktrees\nbonsai root              # go back to repo root\n```\n\n## How worktrees are organized\n\n```\nmyrepo/\n  .bonsai/\n    feature-auth/        ← bonsai feature/auth\n    hotfix-login/        ← bonsai hotfix/login\n  src/\n  package.json\n```\n\n`.bonsai/` is added to `.gitignore` on first use.\n\n## Running from inside a worktree\n\nBonsai detects when you're in a worktree and operates from the repo root automatically:\n\n```sh\ncd .bonsai/feature-auth\nbonsai payments/checkout   # creates .bonsai/payments-checkout from repo root\nbonsai rm feature/auth     # removes and cds back to repo root\nbonsai root                # cd back to repo root\n```\n\n## Requirements\n\n- git ≥ 2.5\n- Node.js ≥ 18\n- zsh or bash\n\n---\n\nMIT © [Avelor](https://github.com/avelor-es)\n","readmeFilename":"README.md","_rev":"1-0529db02de6130afb32f1b80ebedab31"}