Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make instructions to open file in editor clearer #273

Closed
wants to merge 3 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -130,9 +130,19 @@ The following variables can store custom options that will be passed to fzf by t
They are appended last to fzf's options list. Because fzf uses the last instance of an option if it is specified multiple times, custom options will always take precedence. Custom fzf options unlock a variety of customizations and augmentations such as:

- add [key bindings](https://www.mankier.com/1/fzf#Key/Event_Bindings) within fzf to operate on the selected line:
- [open file in Vim](https://github.com/junegunn/fzf/issues/1360)

- [open file in in your `$EDITOR`](https://github.com/junegunn/fzf/issues/1360):

```fish
# set -gx $EDITOR "nvim" # or "vim", or "code", etc.

# Ctrl-o will open the selected file/directory in your editor of choice.
set fzf_dir_opts --bind "ctrl-o:execute($EDITOR {} &> /dev/tty)"
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in case anyone is referencing this in the future, fzf_dir_opts has been renamed to fzf_directory_opts.

```

- [preview image files](https://gitter.im/junegunn/fzf?at=5947962ef6a78eab48620792)
- git reset file

- adjust the preview command or window
- [re-populate fzf's input list on demand](https://github.com/junegunn/fzf/issues/1750)
- change the [search mode](https://github.com/junegunn/fzf#search-syntax)
Expand Down