Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
45 changes: 45 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com), and this project adheres to [Semantic Versioning](https://semver.org).

## [Unreleased]

### Added

### Changed

### Deprecated

### Removed

### Fixed

### Security

## [1.0.0] - 2025-11-14

### Added

- Initial release of `gtr` (Git Worktree Runner)
- Core commands: `new`, `rm`, `go`, `open`, `ai`, `list`, `clean`, `doctor`, `config`, `adapter`, `help`, `version`
- Worktree creation with branch sanitization, remote/local/auto tracking, and `--force --name` multi-worktree support
- Base directory resolution with support for `.` (repo root) and `./path` (inside repo) plus legacy sibling behavior
- Configuration system via `git config` (local→global→system precedence) and multi-value merging (`copy.include`, `hook.postCreate`, etc.)
- Editor adapter framework (cursor, vscode, zed, idea, pycharm, webstorm, vim, nvim, emacs, sublime, nano, atom)
- AI tool adapter framework (aider, claude, codex, cursor, continue)
- Hooks system: `postCreate`, `postRemove` with environment variables (`REPO_ROOT`, `WORKTREE_PATH`, `BRANCH`)
- Smart file copying (include/exclude glob patterns) with security guidance (`.env.example` vs `.env`)
- Shell completions for Bash, Zsh, and Fish
- Diagnostic commands: `doctor` (environment check) and `adapter` (adapter availability)
- Debian packaging assets (`build-deb.sh`, `Makefile`, `debian/` directory)
- Contributor & AI assistant guidance: `.github/instructions/*.instructions.md`, `.github/copilot-instructions.md`, `CLAUDE.md`
- Support for storing worktrees inside the repository via `gtr.worktrees.dir=./<path>`

### Changed

- Improved base directory resolution logic to distinguish `.` (repo root), `./path` (repo-internal) from other relative values (sibling directories)

[Unreleased]: https://github.com/coderabbitai/git-worktree-runner/compare/v1.0.0...HEAD
[1.0.0]: https://github.com/coderabbitai/git-worktree-runner/releases/tag/v1.0.0
17 changes: 9 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,8 @@ gtr.worktrees.prefix = dev-
gtr.defaultBranch = main
```

**⚠️ Important:** If storing worktrees inside the repository, add the directory to `.gitignore`:
> [!IMPORTANT]
> If storing worktrees inside the repository, add the directory to `.gitignore`.

```bash
echo "/.worktrees/" >> .gitignore
Expand Down Expand Up @@ -333,7 +334,8 @@ gtr config add gtr.copy.exclude "**/.env"
gtr config add gtr.copy.exclude "**/secrets.*"
```

**⚠️ Security Note:** Be careful not to copy sensitive files. Use `.env.example` instead of `.env`.
> [!WARNING]
> Be careful not to copy sensitive files. Use `.env.example` instead of `.env`.

### Hooks

Expand Down Expand Up @@ -506,7 +508,8 @@ gtr rm ci-test --yes --delete-branch

### Multiple Worktrees on Same Branch

**⚠️ Advanced Use Only** - Git normally prevents checking out the same branch in multiple worktrees to avoid conflicts. `gtr` supports bypassing this safety check with `--force` and `--name` flags.
> [!TIP]
> Git normally prevents checking out the same branch in multiple worktrees to avoid conflicts. `gtr` supports bypassing this safety check with `--force` and `--name` flags.

**Use cases:**

Expand Down Expand Up @@ -534,7 +537,7 @@ gtr new feature-auth --force --name tests # Creates: feature-auth-tests/
# The --name flag is required with --force to distinguish worktrees
```

**Example: Parallel AI development on one feature**
**Example: Parallel AI development on one feature:**

```bash
# Terminal 1: Backend work
Expand Down Expand Up @@ -613,7 +616,7 @@ find . -path "**/.env.example"

## Architecture

```
```log
git-worktree-runner/
├── bin/gtr # Main executable
├── lib/ # Core libraries
Expand Down Expand Up @@ -696,8 +699,6 @@ Unless required by applicable law or agreed to in writing, software distributed

Built to streamline parallel development workflows with git worktrees. Inspired by the need for simple, configurable worktree management across different development environments.

---

**Happy coding with worktrees! 🚀**
## Happy coding with worktrees! 🚀

For questions or issues, please [open an issue](https://github.com/coderabbitai/git-worktree-runner/issues).