this repo has no description

zsh: worktree shortcuts

seth.computer d9422050 b708b777

verified
+15
+15
zsh/zshenv
··· 4 4 5 5 export DOTFILES_DIR=$HOME/dotfiles 6 6 7 + export TASKS_DIR=$HOME/projects/.tasks 8 + 7 9 export EDITOR=vim 8 10 export BAT_THEME="ansi" 9 11 export DELTA_FEATURES="+side-by-side +line-numbers" ··· 30 32 alias gb="git branch" 31 33 alias gfp="git fetch --prune" 32 34 alias gsw="git switch" 35 + 33 36 alias wtl="git worktree list" 34 37 alias wtp="git worktree prune" 38 + 39 + function wt { 40 + task=${1-"task-$(date +%s)"} 41 + base_branch=${2-$(git branch --show-current)} 42 + repo_folder=$(basename $(pwd)) 43 + 44 + task_dir=$TASKS_DIR/$task 45 + mkdir -p $task_dir 46 + 47 + git worktree add $task_dir/$repo_folder $base_branch 48 + cd $task_dir/$repo_folder 49 + } 35 50 36 51 alias lg="lazygit" 37 52 alias ld="lazydocker"