mirror of
https://github.com/arthur-pbty/arthur-os.git
synced 2026-08-02 04:37:49 +02:00
Allow kitty to preview images when using ff
This commit is contained in:
+10
-1
@@ -6,7 +6,16 @@ if command -v eza &> /dev/null; then
|
||||
alias lta='lt -a'
|
||||
fi
|
||||
|
||||
alias ff="fzf --preview 'bat --style=numbers --color=always {}'"
|
||||
if [[ "$TERM" == "xterm-kitty" ]]; then
|
||||
alias ff="fzf --preview '
|
||||
case \$(file --mime-type -b {}) in
|
||||
image/*) kitty icat --clear --transfer-mode=memory --stdin=no --place=\${FZF_PREVIEW_COLUMNS}x\${FZF_PREVIEW_LINES}@0x0 {} ;;
|
||||
*) bat --style=numbers --color=always {} ;;
|
||||
esac
|
||||
'"
|
||||
else
|
||||
alias ff="fzf --preview 'bat --style=numbers --color=always {}'"
|
||||
fi
|
||||
alias eff='$EDITOR "$(ff)"'
|
||||
|
||||
if command -v zoxide &> /dev/null; then
|
||||
|
||||
Reference in New Issue
Block a user