Rename local path variable in ga() to avoid clobbering zsh PATH (#5115)
Co-authored-by: John Allen <git@porcnick.com>
This commit is contained in:
@@ -7,11 +7,11 @@ ga() {
|
|||||||
|
|
||||||
local branch="$1"
|
local branch="$1"
|
||||||
local base="$(basename "$PWD")"
|
local base="$(basename "$PWD")"
|
||||||
local path="../${base}--${branch}"
|
local wt_path="../${base}--${branch}"
|
||||||
|
|
||||||
git worktree add -b "$branch" "$path"
|
git worktree add -b "$branch" "$wt_path"
|
||||||
mise trust "$path"
|
mise trust "$wt_path"
|
||||||
cd "$path"
|
cd "$wt_path"
|
||||||
}
|
}
|
||||||
|
|
||||||
# Remove worktree and branch from within active worktree directory.
|
# Remove worktree and branch from within active worktree directory.
|
||||||
|
|||||||
Reference in New Issue
Block a user