Fix more tabbing
26bb1f3be3b13d728d34afd0588d8a2a749581bf
1 parent
dfae7a50
.fzy.zsh
+3 -3
| 1 | 1 | # |
|
| 2 | 2 | # fzy shell integration |
|
| 3 | 3 | # |
|
| 4 | - | # Adapted from fzf (https://github.com/junegunn/fzf). |
|
| 4 | + | # Adapted from fzf (https://github.com/junegunn/fzf). |
|
| 5 | 5 | # |
|
| 6 | 6 | # Copyright (c) 2016 Junegunn Choi |
|
| 7 | 7 | # Copyright (c) 2016 Alexis Sellier |
|
| 8 | 8 | # |
|
| 9 | 9 | if [[ $- != *i* ]]; then |
| 14 | 14 | setopt localoptions pipefail 2> /dev/null |
|
| 15 | 15 | command ag --silent -g '' | fzy | while read -r item; do |
|
| 16 | 16 | echo -n "${(q)item}" |
|
| 17 | 17 | done |
|
| 18 | 18 | local ret=$? |
|
| 19 | - | echo |
|
| 19 | + | echo |
|
| 20 | 20 | return $ret |
|
| 21 | 21 | } |
|
| 22 | 22 | ||
| 23 | 23 | fzy-file-widget () { |
|
| 24 | 24 | LBUFFER="${LBUFFER}$(__fzy_fsel)" |
| 35 | 35 | bindkey '^P' fzy-file-widget |
|
| 36 | 36 | ||
| 37 | 37 | fzy-history-widget () { |
|
| 38 | 38 | local selected num |
|
| 39 | 39 | setopt localoptions noglobsubst pipefail 2> /dev/null |
|
| 40 | - | selected=( $(fc -l -r 1 | fzy -q "${LBUFFER//$/\\$}") ) |
|
| 40 | + | selected=( $(fc -l -r 1 | fzy -q "${LBUFFER//$/\\$}") ) |
|
| 41 | 41 | local ret=$? |
|
| 42 | 42 | if [[ -n ${selected} ]]; then |
|
| 43 | 43 | num=${selected[1]} |
|
| 44 | 44 | if [[ -n ${num} ]]; then |
|
| 45 | 45 | zle vi-fetch-history -n ${num} |