mirror of
https://github.com/junegunn/fzf.git
synced 2025-11-20 09:33:42 -05:00
Remove :Buffers delete example as it will never work reliably unless we'd have junegunn/fzf#2019 fixed
@@ -327,22 +327,3 @@ command! -bang -nargs=* LoadTemplate call fzf#run({
|
|||||||
\ 'sink': function('<sid>read_template_into_buffer')
|
\ 'sink': function('<sid>read_template_into_buffer')
|
||||||
\ })
|
\ })
|
||||||
```
|
```
|
||||||
|
|
||||||
### Delete buffers from `:Buffers`
|
|
||||||
|
|
||||||
This customization is an _attempt_, that sometimes doesn't work, to make the key `D` in `:Buffers`' interface, delete buffers. See the issues reported with this customization [here](https://github.com/junegunn/fzf.vim/pull/1044#issuecomment-651199164). An additional change this does to `:Buffers`' interface, is to make fzf reload the list of available buffers upon deletion, while allowing to delete multiple buffers as well. The requirements are:
|
|
||||||
|
|
||||||
- https://github.com/mhinz/neovim-remote .
|
|
||||||
- fzf.vim with this PR merged: https://github.com/junegunn/fzf.vim/pull/1044
|
|
||||||
- fzf 19.0 or later.
|
|
||||||
|
|
||||||
```vim
|
|
||||||
command! -bar -bang -nargs=? -complete=buffer Buffers call
|
|
||||||
\ fzf#vim#buffers(
|
|
||||||
\ <q-args>,
|
|
||||||
\ {'options': [
|
|
||||||
\ '--bind=D:execute@nvr -c "bw $(echo {+1} | sed "s/\[\([0-9]\)\]/\1/g")"@+reload@nvr --remote-expr "join(map(fzf#vim#buflisted_sorted(), \"fzf#vim#format_buffer(v:val)\"), \"\n\")"@',
|
|
||||||
\ '--multi'
|
|
||||||
\ ]},
|
|
||||||
\ <bang>0)
|
|
||||||
```
|
|
||||||
Reference in New Issue
Block a user