From cb22e1dd063a59a3b21dbdfd7f7d9170d9bb3c97 Mon Sep 17 00:00:00 2001 From: Mari Date: Wed, 13 May 2020 15:27:15 -0400 Subject: [PATCH] Autocommitted updated scripts from mari-wovn --- per-host/mari-wovn/.bash_aliases | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/per-host/mari-wovn/.bash_aliases b/per-host/mari-wovn/.bash_aliases index 92c896f..ee04cd8 100644 --- a/per-host/mari-wovn/.bash_aliases +++ b/per-host/mari-wovn/.bash_aliases @@ -20,6 +20,7 @@ function tmux_start_branch() { function start_branch() { branch=${1:?} + branch=${branch#feature/} ( # set -o errexit # Can't do this inside a function set -o nounset @@ -99,5 +100,8 @@ function delete_local_branch() { worktree="$(git worktree list --porcelain | grep -B2 ${branch} | cut -d' ' -f2 | head -n1)" || exit "$?" git worktree remove "$worktree" || exit "$?" git branch -d "$branch" || exit "$?" - ) && cd ~/equalizer.git + ); local lastexit="$?" + if [[ ! -d "$PWD" ]]; then + cd ~/equalizer.git + fi }