mirror of
https://github.com/junegunn/fzf.git
synced 2025-11-19 09:03:43 -05:00
add --ansi, as remarked in https://github.com/junegunn/fzf/issues/1175#issuecomment-350938973
@@ -399,7 +399,7 @@ sort -u | awk '{print "\x1b[34;1mbranch\x1b[m\t" $1}') || return
|
|||||||
target=$(
|
target=$(
|
||||||
(echo "$tags"; echo "$branches") |
|
(echo "$tags"; echo "$branches") |
|
||||||
fzf --no-hscroll --no-multi --delimiter="\t" -n 2 \
|
fzf --no-hscroll --no-multi --delimiter="\t" -n 2 \
|
||||||
--preview="git log -200 --pretty=format:%s $(echo {+2..} | sed 's/$/../' )" ) || return
|
--ansi --preview="git log -200 --pretty=format:%s $(echo {+2..} | sed 's/$/../' )" ) || return
|
||||||
git checkout $(echo "$target" | awk '{print $2}')
|
git checkout $(echo "$target" | awk '{print $2}')
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -438,7 +438,7 @@ fcoc_preview() {
|
|||||||
local commit
|
local commit
|
||||||
commit=$( glNoGraph |
|
commit=$( glNoGraph |
|
||||||
fzf --no-sort --reverse --tiebreak=index --no-multi \
|
fzf --no-sort --reverse --tiebreak=index --no-multi \
|
||||||
--preview $_viewGitLogLine ) &&
|
--ansi --preview $_viewGitLogLine ) &&
|
||||||
git checkout $(echo "$commit" | sed "s/ .*//")
|
git checkout $(echo "$commit" | sed "s/ .*//")
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -446,7 +446,7 @@ fcoc_preview() {
|
|||||||
fshow_preview() {
|
fshow_preview() {
|
||||||
glNoGraph |
|
glNoGraph |
|
||||||
fzf --no-sort --reverse --tiebreak=index --no-multi \
|
fzf --no-sort --reverse --tiebreak=index --no-multi \
|
||||||
--preview $_viewGitLogLine \
|
--ansi --preview $_viewGitLogLine \
|
||||||
--header "enter to view, alt-y to copy hash" \
|
--header "enter to view, alt-y to copy hash" \
|
||||||
--bind "enter:execute:$_viewGitLogLine | less -R" \
|
--bind "enter:execute:$_viewGitLogLine | less -R" \
|
||||||
--bind "alt-y:execute:$_gitLogLineToHash | xclip"
|
--bind "alt-y:execute:$_gitLogLineToHash | xclip"
|
||||||
|
|||||||
Reference in New Issue
Block a user