fix example code
This commit is contained in:
parent
abb8ac7911
commit
cd69b56bab
1 changed files with 2 additions and 2 deletions
|
@ -23,7 +23,7 @@ fzf-mode key bindings. User should not remember all possible commands.
|
||||||
# after fzf returns its result
|
# after fzf returns its result
|
||||||
# Second argument is a command to the fzf itself, which will be used
|
# Second argument is a command to the fzf itself, which will be used
|
||||||
# to provide list for fzf to show.
|
# to provide list for fzf to show.
|
||||||
fzf "echo $1" "echo 'thisisanexample'"
|
fzf "echo $1" "echo 'this is an example' | tr ' ' '\n'"
|
||||||
}
|
}
|
||||||
|
|
||||||
map global fzf -docstring "fzf example command" e '<esc>: fzf-good-example<ret>'
|
map global fzf -docstring "fzf example command" e '<esc>: fzf-good-example<ret>'
|
||||||
|
@ -33,7 +33,7 @@ map global fzf -docstring "fzf example command" e '<esc>: fzf-good-example<ret>'
|
||||||
Bad code:
|
Bad code:
|
||||||
```kak
|
```kak
|
||||||
# example
|
# example
|
||||||
def fzf-good-exmpl %{ fzf "echo $1" "echo 'actually I'm bad example'" }
|
def fzf-good-exmpl %{ fzf "echo $1" "echo 'actually I''m bad example' | tr ' ' '\n'" }
|
||||||
```
|
```
|
||||||
|
|
||||||
Although such code is short, it is not *safe*, because reloading kakrc will cause an error here.
|
Although such code is short, it is not *safe*, because reloading kakrc will cause an error here.
|
||||||
|
|
Loading…
Reference in a new issue