Releases: liamawhite/worktree
v0.2.0
Changelog
Installation
Download Binary
Choose the appropriate binary for your platform from the assets below:
Linux (x86_64)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.2.0/worktree_Linux_x86_64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/Linux (ARM64)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.2.0/worktree_Linux_arm64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/macOS (Intel)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.2.0/worktree_Darwin_x86_64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/macOS (Apple Silicon)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.2.0/worktree_Darwin_arm64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/Verify Installation
worktree --versionOptional: Shell Integration for Directory Switching
To enable automatic directory changes when using worktree add and worktree switch commands, add this function to your shell profile:
(~/.bashrc, ~/.bash_profile, ~/.zshrc):
worktree() {
local cmd="$1"
# Commands that should change directory
if [[ "$cmd" == "add" || "$cmd" == "switch" || "$cmd" == "sw" || "$cmd" == "setup" ]]; then
# Capture stderr to look for WT_CHDIR while preserving stdout and interactive TUI
local temp_file
temp_file=$(mktemp)
# Run command with stderr redirected to temp file
command worktree "$@" 2> >(tee "$temp_file" >&2)
local exit_code=$?
# Look for directory change indicator in stderr
local target_dir
target_dir=$(grep "^WT_CHDIR:" "$temp_file" 2>/dev/null | sed 's/^WT_CHDIR://')
# Clean up temp file
rm -f "$temp_file"
# Change directory if target was specified
if [[ -n "$target_dir" && -d "$target_dir" ]]; then
cd "$target_dir" || echo "Warning: Failed to change to directory: $target_dir"
fi
return $exit_code
else
# For all other commands, just run normally
command worktree "$@"
fi
}After adding this function and restarting your shell (or running source ~/.bashrc/source ~/.zshrc), the worktree add, worktree switch, and worktree setup commands will automatically change your current directory to the worktree location.
Verification with Checksums
Download checksums.txt and verify your binary:
sha256sum -c checksums.txtReleased by GoReleaser.
v0.1.3
Changelog
Installation
Download Binary
Choose the appropriate binary for your platform from the assets below:
Linux (x86_64)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.1.3/worktree_Linux_x86_64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/Linux (ARM64)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.1.3/worktree_Linux_arm64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/macOS (Intel)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.1.3/worktree_Darwin_x86_64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/macOS (Apple Silicon)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.1.3/worktree_Darwin_arm64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/Verify Installation
worktree --versionOptional: Shell Integration for Directory Switching
To enable automatic directory changes when using worktree add and worktree switch commands, add this function to your shell profile:
(~/.bashrc, ~/.bash_profile, ~/.zshrc):
worktree() {
local cmd="$1"
# Commands that should change directory
if [[ "$cmd" == "add" || "$cmd" == "switch" || "$cmd" == "sw" || "$cmd" == "setup" ]]; then
# Capture stderr to look for WT_CHDIR while preserving stdout and interactive TUI
local temp_file
temp_file=$(mktemp)
# Run command with stderr redirected to temp file
command worktree "$@" 2> >(tee "$temp_file" >&2)
local exit_code=$?
# Look for directory change indicator in stderr
local target_dir
target_dir=$(grep "^WT_CHDIR:" "$temp_file" 2>/dev/null | sed 's/^WT_CHDIR://')
# Clean up temp file
rm -f "$temp_file"
# Change directory if target was specified
if [[ -n "$target_dir" && -d "$target_dir" ]]; then
cd "$target_dir" || echo "Warning: Failed to change to directory: $target_dir"
fi
return $exit_code
else
# For all other commands, just run normally
command worktree "$@"
fi
}After adding this function and restarting your shell (or running source ~/.bashrc/source ~/.zshrc), the worktree add, worktree switch, and worktree setup commands will automatically change your current directory to the worktree location.
Verification with Checksums
Download checksums.txt and verify your binary:
sha256sum -c checksums.txtReleased by GoReleaser.
v0.1.2
Changelog
- d21aa65 Add Claude Code GitHub Workflow (#9)
- 660750f feat: add version command and -v flag (#10)
- 69b32aa feat: auto-change directory after setup command (#11)
Installation
Download Binary
Choose the appropriate binary for your platform from the assets below:
Linux (x86_64)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.1.2/worktree_Linux_x86_64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/Linux (ARM64)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.1.2/worktree_Linux_arm64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/macOS (Intel)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.1.2/worktree_Darwin_x86_64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/macOS (Apple Silicon)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.1.2/worktree_Darwin_arm64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/Verify Installation
worktree --versionOptional: Shell Integration for Directory Switching
To enable automatic directory changes when using worktree add and worktree switch commands, add this function to your shell profile:
(~/.bashrc, ~/.bash_profile, ~/.zshrc):
worktree() {
local cmd="$1"
# Commands that should change directory
if [[ "$cmd" == "add" || "$cmd" == "switch" || "$cmd" == "sw" ]]; then
# Capture stderr to look for WT_CHDIR while preserving stdout and interactive TUI
local temp_file
temp_file=$(mktemp)
# Run command with stderr redirected to temp file
command worktree "$@" 2> >(tee "$temp_file" >&2)
local exit_code=$?
# Look for directory change indicator in stderr
local target_dir
target_dir=$(grep "^WT_CHDIR:" "$temp_file" 2>/dev/null | sed 's/^WT_CHDIR://')
# Clean up temp file
rm -f "$temp_file"
# Change directory if target was specified
if [[ -n "$target_dir" && -d "$target_dir" ]]; then
cd "$target_dir" || echo "Warning: Failed to change to directory: $target_dir"
fi
return $exit_code
else
# For all other commands, just run normally
command worktree "$@"
fi
}After adding this function and restarting your shell (or running source ~/.bashrc/source ~/.zshrc), the worktree add and worktree switch commands will automatically change your current directory to the worktree location.
Verification with Checksums
Download checksums.txt and verify your binary:
sha256sum -c checksums.txtReleased by GoReleaser.
v0.1.1
Changelog
Installation
Download Binary
Choose the appropriate binary for your platform from the assets below:
Linux (x86_64)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.1.1/worktree_Linux_x86_64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/Linux (ARM64)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.1.1/worktree_Linux_arm64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/macOS (Intel)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.1.1/worktree_Darwin_x86_64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/macOS (Apple Silicon)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.1.1/worktree_Darwin_arm64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/Verify Installation
worktree --versionOptional: Shell Integration for Directory Switching
To enable automatic directory changes when using worktree add and worktree switch commands, add this function to your shell profile:
(~/.bashrc, ~/.bash_profile, ~/.zshrc):
worktree() {
local cmd="$1"
# Commands that should change directory
if [[ "$cmd" == "add" || "$cmd" == "switch" || "$cmd" == "sw" ]]; then
# Capture stderr to look for WT_CHDIR while preserving stdout and interactive TUI
local temp_file
temp_file=$(mktemp)
# Run command with stderr redirected to temp file
command worktree "$@" 2> >(tee "$temp_file" >&2)
local exit_code=$?
# Look for directory change indicator in stderr
local target_dir
target_dir=$(grep "^WT_CHDIR:" "$temp_file" 2>/dev/null | sed 's/^WT_CHDIR://')
# Clean up temp file
rm -f "$temp_file"
# Change directory if target was specified
if [[ -n "$target_dir" && -d "$target_dir" ]]; then
cd "$target_dir" || echo "Warning: Failed to change to directory: $target_dir"
fi
return $exit_code
else
# For all other commands, just run normally
command worktree "$@"
fi
}After adding this function and restarting your shell (or running source ~/.bashrc/source ~/.zshrc), the worktree add and worktree switch commands will automatically change your current directory to the worktree location.
Verification with Checksums
Download checksums.txt and verify your binary:
sha256sum -c checksums.txtReleased by GoReleaser.
v0.1.0
Changelog
- c5a5b34 Fix ssh based cloning
- a429231 Merge pull request #7 from liamawhite/ghe-debug
- 1039f13 add config section to readme
- bf30579 format
- 26438f7 readme fixes
Installation
Download Binary
Choose the appropriate binary for your platform from the assets below:
Linux (x86_64)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.1.0/worktree_Linux_x86_64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/Linux (ARM64)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.1.0/worktree_Linux_arm64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/macOS (Intel)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.1.0/worktree_Darwin_x86_64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/macOS (Apple Silicon)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.1.0/worktree_Darwin_arm64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/Verify Installation
worktree --versionOptional: Shell Integration for Directory Switching
To enable automatic directory changes when using worktree add and worktree switch commands, add this function to your shell profile:
(~/.bashrc, ~/.bash_profile, ~/.zshrc):
worktree() {
local cmd="$1"
# Commands that should change directory
if [[ "$cmd" == "add" || "$cmd" == "switch" || "$cmd" == "sw" ]]; then
# Capture stderr to look for WT_CHDIR while preserving stdout and interactive TUI
local temp_file
temp_file=$(mktemp)
# Run command with stderr redirected to temp file
command worktree "$@" 2> >(tee "$temp_file" >&2)
local exit_code=$?
# Look for directory change indicator in stderr
local target_dir
target_dir=$(grep "^WT_CHDIR:" "$temp_file" 2>/dev/null | sed 's/^WT_CHDIR://')
# Clean up temp file
rm -f "$temp_file"
# Change directory if target was specified
if [[ -n "$target_dir" && -d "$target_dir" ]]; then
cd "$target_dir" || echo "Warning: Failed to change to directory: $target_dir"
fi
return $exit_code
else
# For all other commands, just run normally
command worktree "$@"
fi
}After adding this function and restarting your shell (or running source ~/.bashrc/source ~/.zshrc), the worktree add and worktree switch commands will automatically change your current directory to the worktree location.
Verification with Checksums
Download checksums.txt and verify your binary:
sha256sum -c checksums.txtReleased by GoReleaser.
v0.0.1
Changelog
- 5e4d164 Initial commit
- 9c24978 Merge pull request #1 from liamawhite/initial-func
- 38d11b7 Merge pull request #2 from liamawhite/release-things
- 40d2340 Merge pull request #3 from liamawhite/test-fixes
- 2ae7d8b Merge pull request #4 from liamawhite/more-test-fixes
- f0c84d4 Merge pull request #5 from liamawhite/more-test-fixes-2
- b3eab8e Update Claude settings permissions
- 81b42d4 chore: add license headers and fix linting issues
- 01da568 dont build windows binaries for now...
- aad5fd7 feat(shell): improve interactive selector and fix config test leakage
- 4a98d78 feat: add automatic directory switching for add/switch commands
- 260c163 feat: add comprehensive worktree management system
- 8c902cb feat: add git remote verification to integration tests
- ed49116 feat: add release job to test workflow
- c4780bf feat: change directory to root when removing current worktree
- bab6928 fix test wf name
- f2494f6 fix: resolve linting errors and test failures
- b30236e more fixes
Installation
Download Binary
Choose the appropriate binary for your platform from the assets below:
Linux (x86_64)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.0.1/worktree_Linux_x86_64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/Linux (ARM64)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.0.1/worktree_Linux_arm64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/macOS (Intel)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.0.1/worktree_Darwin_x86_64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/macOS (Apple Silicon)
curl -L https://github.com/liamawhite/worktree/releases/download/v0.0.1/worktree_Darwin_arm64.tar.gz | tar xz
chmod +x worktree
sudo mv worktree /usr/local/bin/Verify Installation
worktree --versionOptional: Shell Integration for Directory Switching
To enable automatic directory changes when using worktree add and worktree switch commands, add this function to your shell profile:
(~/.bashrc, ~/.bash_profile, ~/.zshrc):
worktree() {
local cmd="$1"
# Commands that should change directory
if [[ "$cmd" == "add" || "$cmd" == "switch" || "$cmd" == "sw" ]]; then
# Capture stderr to look for WT_CHDIR while preserving stdout and interactive TUI
local temp_file
temp_file=$(mktemp)
# Run command with stderr redirected to temp file
command worktree "$@" 2> >(tee "$temp_file" >&2)
local exit_code=$?
# Look for directory change indicator in stderr
local target_dir
target_dir=$(grep "^WT_CHDIR:" "$temp_file" 2>/dev/null | sed 's/^WT_CHDIR://')
# Clean up temp file
rm -f "$temp_file"
# Change directory if target was specified
if [[ -n "$target_dir" && -d "$target_dir" ]]; then
cd "$target_dir" || echo "Warning: Failed to change to directory: $target_dir"
fi
return $exit_code
else
# For all other commands, just run normally
command worktree "$@"
fi
}After adding this function and restarting your shell (or running source ~/.bashrc/source ~/.zshrc), the worktree add and worktree switch commands will automatically change your current directory to the worktree location.
Verification with Checksums
Download checksums.txt and verify your binary:
sha256sum -c checksums.txtReleased by GoReleaser.