mirror of https://github.com/chatton/dotfiles
adding bash_profile
parent
85fd11c824
commit
2dc1a2f98b
@ -0,0 +1,15 @@
|
|||||||
|
function _branches() {
|
||||||
|
if [ -n "$1" ]; then
|
||||||
|
echo "$1"
|
||||||
|
return
|
||||||
|
else
|
||||||
|
git for-each-ref --sort=committerdate refs/heads/ | awk -F'heads/' '{ print $NF }' | fzf
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
function cb() {
|
||||||
|
branch=$(_branches)
|
||||||
|
git checkout "${branch}"
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
Loading…
Reference in New Issue