mirror of
https://github.com/Llewellynvdm/fzf.git
synced 2024-12-23 11:29:01 +00:00
Implement CTRL-D
This commit is contained in:
parent
9dac12cb32
commit
c3a4e4cd23
@ -123,6 +123,7 @@ The following readline key bindings should also work as expected.
|
|||||||
|
|
||||||
- CTRL-A / CTRL-E
|
- CTRL-A / CTRL-E
|
||||||
- CTRL-B / CTRL-F
|
- CTRL-B / CTRL-F
|
||||||
|
- CTRL-H / CTRL-D
|
||||||
- CTRL-W / CTRL-U / CTRL-Y
|
- CTRL-W / CTRL-U / CTRL-Y
|
||||||
- ALT-B / ALT-F
|
- ALT-B / ALT-F
|
||||||
|
|
||||||
|
10
fzf
10
fzf
@ -7,7 +7,7 @@
|
|||||||
# / __/ / /_/ __/
|
# / __/ / /_/ __/
|
||||||
# /_/ /___/_/ Fuzzy finder for your shell
|
# /_/ /___/_/ Fuzzy finder for your shell
|
||||||
#
|
#
|
||||||
# Version: 0.8.5 (Jun 7, 2014)
|
# Version: 0.8.5 (Jun 12, 2014)
|
||||||
#
|
#
|
||||||
# Author: Junegunn Choi
|
# Author: Junegunn Choi
|
||||||
# URL: https://github.com/junegunn/fzf
|
# URL: https://github.com/junegunn/fzf
|
||||||
@ -881,7 +881,13 @@ class FZF
|
|||||||
}
|
}
|
||||||
actions = {
|
actions = {
|
||||||
:esc => proc { exit 1 },
|
:esc => proc { exit 1 },
|
||||||
ctrl(:d) => proc { exit 1 if input.empty? },
|
ctrl(:d) => proc {
|
||||||
|
if input.empty?
|
||||||
|
exit 1
|
||||||
|
elsif cursor < input.length
|
||||||
|
input = input[0...cursor] + input[(cursor + 1)..-1]
|
||||||
|
end
|
||||||
|
},
|
||||||
ctrl(:m) => proc {
|
ctrl(:m) => proc {
|
||||||
got = pick
|
got = pick
|
||||||
exit 0
|
exit 0
|
||||||
|
Loading…
Reference in New Issue
Block a user