git: logsearch date to left column

This commit is contained in:
Charles Gould 2021-01-16 01:02:53 -05:00
parent 7ef633fa24
commit 3a5b050993
2 changed files with 3 additions and 3 deletions

View File

@ -25,9 +25,9 @@ function __fzf_git_log
else
set -l output (
command git logsearch |
fzf --ansi --tiebreak=index --preview='git show --color {1}' --preview-window='right:70%:hidden:wrap' --bind='?:toggle-preview' --header='? to preview'
fzf --ansi --tiebreak=index --preview='git show --color {2}' --preview-window='right:70%:hidden:wrap' --bind='?:toggle-preview' --header='? to preview'
)
if set -l commit_hash (string split --max 1 " " $output)[1]
if set -l commit_hash (string split --max 2 " " $output)[2]
commandline -i $commit_hash
end
end

View File

@ -9,7 +9,7 @@
branchsort = branch --sort='-committerdate' --format='%(HEAD) %(color:blue)%(committerdate:short)%(color:reset) %(if)%(worktreepath)%(then)%(color:reverse yellow)%(refname:short)%(color:reset)%(else)%(color:yellow)%(refname:short)%(color:reset)%(end) %(color:green)%(upstream:short)%(color:reset)'
can = commit --amend --no-edit
cand = commit --amend --no-edit --date=now
logsearch = log --color=always --format=tformat:'%C(yellow)%h%C(reset) %C(blue)%cs%C(reset) %C(normal)%s%C(reset)'
logsearch = log --color=always --format=tformat:'%C(blue)%cs%C(reset) %C(yellow)%h%C(reset) %C(normal)%s%C(reset)'
rbi = rebase --interactive
wipe = restore --staged --worktree
[color]