diff options
| author | Alec Goncharow <alec@goncharow.dev> | 2025-04-20 15:46:33 -0400 |
|---|---|---|
| committer | Alec Goncharow <alec@goncharow.dev> | 2025-04-20 15:48:01 -0400 |
| commit | 973673083f215451b7674a22533b4e7dfdfb81fd (patch) | |
| tree | be7942cc9e98755edeb24427e4776b75e7485f73 /functions | |
| parent | 78efc3eb493b40ad2f79408a47bb873b5eea9db0 (diff) | |
maybe useful
idk
Diffstat (limited to 'functions')
| -rwxr-xr-x | functions/fzf.sh | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/functions/fzf.sh b/functions/fzf.sh index 8761247..e806da1 100755 --- a/functions/fzf.sh +++ b/functions/fzf.sh @@ -7,11 +7,12 @@ function frg { --delimiter ':' \ --preview "bat --color=always {1} --theme='gruvbox-dark' --highlight-line {2}" \ --preview-window 'up,60%,border-bottom,+{2}+3/3,~3') - file=${result%%:*} - linenumber=$(echo "${result}" | cut -d: -f2) - if [[ -n "$file" ]]; then - nvim +"${linenumber}" "$file" - fi + + file=${result%%:*} + linenumber=$(echo "${result}" | cut -d: -f2) + if [[ -n "$file" ]]; then + nvim +"${linenumber}" "$file" + fi } alias rgf=frg |
