mirror of
https://github.com/mintycube/dotfiles.git
synced 2024-10-22 14:05:41 +02:00
55 lines
1.2 KiB
Bash
Executable File
55 lines
1.2 KiB
Bash
Executable File
#!/bin/sh
|
|
|
|
dwmc setlayoutex 2
|
|
|
|
search_dir="${1:-.}"
|
|
preview='bat --style=header,numbers --color=always {}'
|
|
|
|
fd_command="fd . \
|
|
--type file \
|
|
--hidden \
|
|
--follow \
|
|
--color always \
|
|
--exclude .git \
|
|
--exclude .github \
|
|
--exclude *.o \
|
|
--exclude *.pyc \
|
|
--exclude node_modules \
|
|
--full-path \"$search_dir\""
|
|
|
|
fzf_command="fzf \
|
|
--ansi \
|
|
--height=100% \
|
|
--keep-right \
|
|
--layout=reverse \
|
|
--scheme=path \
|
|
--multi \
|
|
--preview=\"[[ -n {1} ]] && $preview\" \
|
|
--preview-window='bottom,60%,border-top' \
|
|
--scrollbar='▐' --info=inline-right \
|
|
--margin=5%,10%,5%,10% --border=none \
|
|
--highlight-line \
|
|
--color=bg+:#2d3f76 \
|
|
--color=bg:#1e2030 \
|
|
--color=border:#589ed7 \
|
|
--color=fg:#c8d3f5 \
|
|
--color=gutter:#1e2030 \
|
|
--color=header:#ff966c \
|
|
--color=hl+:#65bcff \
|
|
--color=hl:#65bcff \
|
|
--color=info:#545c7e \
|
|
--color=marker:#ff007c \
|
|
--color=pointer:#ff007c \
|
|
--color=prompt:#65bcff \
|
|
--color=query:#c8d3f5:regular \
|
|
--color=scrollbar:#589ed7 \
|
|
--color=separator:#ff966c \
|
|
--color=spinner:#ff007c \
|
|
--prompt=' ' --pointer=' ' --ellipsis='' "
|
|
|
|
eval "$fd_command" | eval "$fzf_command"
|
|
|
|
dwmc setlayoutex 0
|
|
|
|
exit 0
|