mirror of
https://github.com/wfxr/forgit.git
synced 2026-09-10 07:16:23 -04:00
Merge pull request #196 from pablombg/fix-checkout-branch
Fix gcb problems with verbosity and collation
This commit is contained in:
commit
6186ee7e47
|
|
@ -257,7 +257,7 @@ function forgit::checkout::branch -d "git checkout branch selector" --argument-n
|
|||
$FORGIT_CHECKOUT_BRANCH_FZF_OPTS
|
||||
"
|
||||
|
||||
set cmd "git branch --color=always --verbose --all | sort -k1.1,1.1 -r"
|
||||
set cmd "git branch --color=always --all | LC_ALL=C sort -k1.1,1.1 -rs"
|
||||
set branch (eval "$cmd" | FZF_DEFAULT_OPTS="$opts" fzf | awk '{print $1}')
|
||||
|
||||
test -z "$branch" && return 1
|
||||
|
|
|
|||
|
|
@ -235,7 +235,7 @@ forgit::checkout::branch() {
|
|||
forgit::inside_work_tree || return 1
|
||||
[[ $# -ne 0 ]] && { git checkout -b "$@"; return $?; }
|
||||
local cmd preview opts branch
|
||||
cmd="git branch --color=always --verbose --all | sort -k1.1,1.1 -r"
|
||||
cmd="git branch --color=always --all | LC_ALL=C sort -k1.1,1.1 -rs"
|
||||
preview="git log {1} --graph --pretty=format:'$forgit_log_format' --color=always --abbrev-commit --date=relative"
|
||||
opts="
|
||||
$FORGIT_FZF_DEFAULT_OPTS
|
||||
|
|
|
|||
Loading…
Reference in a new issue