Skip to content
Snippets Groups Projects
Commit 75b666bf authored by Junegunn Choi's avatar Junegunn Choi
Browse files

Update README (replace backticks with $())

As reported in #2, backticks on oh-my-zsh (with TERM=xterm*)
makes fzf run twice. This should be a bug of oh-my-zsh,
but for now using $() seems to be a quick workaround.
parent 3f73554a
No related branches found
No related tags found
No related merge requests found
......@@ -89,7 +89,7 @@ files excluding hidden ones. (You can override the default command with
`FZF_DEFAULT_COMMAND`)
```sh
vim `fzf`
vim $(fzf)
```
If you want to preserve the exact sequence of the input, provide `--no-sort` (or
......@@ -136,17 +136,17 @@ Useful bash examples
```sh
# vimf - Open selected file in Vim
vimf() {
FILE=`fzf` && vim "$FILE"
FILE=$(fzf) && vim "$FILE"
}
# fd - cd to selected directory
fd() {
DIR=`find ${1:-*} -path '*/\.*' -prune -o -type d -print 2> /dev/null | fzf` && cd "$DIR"
DIR=$(find ${1:-*} -path '*/\.*' -prune -o -type d -print 2> /dev/null | fzf) && cd "$DIR"
}
# fda - including hidden directories
fda() {
DIR=`find ${1:-*} -type d 2> /dev/null | fzf` && cd "$DIR"
DIR=$(find ${1:-*} -type d 2> /dev/null | fzf) && cd "$DIR"
}
# fh - repeat history
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment