summaryrefslogtreecommitdiffstats
path: root/shell/key-bindings.zsh
AgeCommit message (Collapse)Author
2021-02-03[zsh] Don't run precmd hooks in cd widget (#2340)Marlon Richert
`precmd` hooks expect the Zsh Line Editor to not be active. Running these when the ZLE is active can lead to unpredictable results. See https://github.com/marlonrichert/zsh-autocomplete/issues/180
2021-01-03Revert "[zsh] Use shell redirection (#2281)"Junegunn Choi
This reverts commit e9bc7331bde238e84f24b76ebb1f5e18799b15c4. The change is no longer necessary since 090dee8.
2021-01-01[shell] Disable CTRL-ZJunegunn Choi
Fix #2289
2020-12-23[zsh] Use shell redirection (#2281)林千里
zsh sends SIGCONT when running fzf in a pipe in certain cases, causing mouse mode to become disabled Fix #2101
2020-12-09Revert "[zsh] Reload shared history before searching (#2251)"Junegunn Choi
This reverts commit b62a74b3156540cea4f12cf1d092cba77cb1db67. https://github.com/junegunn/fzf/pull/2251#issuecomment-740551383
2020-12-05[zsh] Reload shared history before searching (#2251)Martin Polden
2020-11-25[zsh] Declare variable as local before assignment (#2266)ratijas
2020-10-03[zsh] Keep current $BUFFER on ALT-CJunegunn Choi
Ideally, we could only use `print -sr` to update the command history. However, the "cd" command by ALT-C is added to the history only after we finalize the current command by pressing an additional enter key. i.e. The cd command from ALT-C is not visible when you hit Up arrow. But it appears once you hit enter key. So when the current buffer is empty, we use `zle accept-line` so that the command history is immediately updated. Close #2200
2020-10-02[zsh] Record cd execution in history (#2193)octaltree
2020-09-02[zsh] Fix the regular expression (#2140)Yuji Nakao
Fix the regular expression to capture the command containing asterisk.
2020-05-23Revert file mode of key-bindings.zshJunegunn Choi
2020-04-24[zsh] Make CTRL-R work with older Perls (#2003)Slaven Rezić
s///r is only available since perl 5.14. The Perl oneliner was changed to work with older Perls, possibly even with 5.000. Fix #2001
2020-04-03[fzf-tmux] Fall back to plain fzf when split failedJunegunn Choi
2020-04-03[fzf-tmux] Add option to start fzf in tmux popup windowJunegunn Choi
Requires latest tmux built from source (e.g. brew install tmux --HEAD) Examples: # 50%/50% width and height on the center of the screen fzf-tmux -p # 80%/80% fzf-tmux -p80% # 80%/40% fzf-tmux -p80%,40% # Separate -w and -h fzf-tmux -w80% -h40% # 80%/40% at position (0, 0) fzf-tmux -w80% -h40% -x0 -y0 You can configure key bindings and fuzzy completion to open in tmux popup window like so: FZF_TMUX_OPTS='-p 80%'
2020-03-30[zsh] Ensure that fzf code always parses the same way (#1944)Roman Perepelitsa
At the top of each zsh file options are set to their standard values (those marked with <Z> in `man zshoptions`) and `aliases` option is disabled. At the bottom of the file the original options are restored. Fix #1938
2020-03-29[shell] Update CTRL-R to remove duplicate commandsJunegunn Choi
Close #1940 Related: #1363 #749 #270 #49 #88 #492 #600
2019-12-01[zsh] Prevent the current directory from appearing as `~dir` in prompts (#1774)midchildan
The zsh version of the cd widget sets the variable `dir` to the path of the target directory before invoking `cd`. This causes zsh to treat the target directory as a named directory, which has the effect of zsh substituting '%~' with '~dir' instead of the proper path when it performs prompt expansion. This commit will cause the widget to unset `dir` before redrawing the prompt to fix this issue. Details of zsh prompt expansion can be found in: http://zsh.sourceforge.net/Doc/Release/Prompt-Expansion.html
2019-10-17[zsh] Suppress global alias expansion in widget functionsJunegunn Choi
Close #1708
2018-10-05[zsh] Fix multiline prompt issue with 'zle reset-prompt' (#1397)Paul Frybarger
Close #867 Close #1256
2017-11-14[zsh] Fire zsh precmd functions after cd (#1136)Aaron Jensen
Fixes #915
2017-10-20[zsh] Use fc -r instead of fzf --tac to speed up loadtime (#1097)Daniel Schaffrath
Reference: http://zsh.sourceforge.net/Doc/Release/Shell-Builtin-Commands.html > The flag -r reverses the order of the events
2017-10-10Don't do shell quoting for weird chars (#1079)Ionel Cristian Mărieș
* Don't do shell quoting for weird chars This would prevent tabs from being escaped as `$'\t'` (definitely not what I would want to see as initial value in the search). * Do different escape.
2017-03-03[zsh] Use setopt noposixbuiltins instead of emulate -L zshJunegunn Choi
Close #858 https://github.com/junegunn/fzf/commit/3a6af27586c65bb9243c5af7c43a40619503db52#commitcomment-21135641
2017-03-03Revert "[zsh] emulate -L zsh to avoid issues with incompatible options"Junegunn Choi
This reverts commit 3a6af27586c65bb9243c5af7c43a40619503db52.
2017-03-03[shell] Enable sorting by default in CTRL-RJunegunn Choi
CTRL-R binding used to start with --no-sort to list the matched commands in chronological order. However, it has been a constant source of confusion. Let's enable it by default from now on. The sorted result shouldn't be too confusing as we use --tiebreak=index.
2017-03-01[zsh] emulate -L zsh to avoid issues with incompatible optionsJunegunn Choi
Close #858
2017-02-19Exclude sysfs in find commandsJunegunn Choi
2017-02-16[shell] Replace `sed` with `-mindepth 1` and `cut` (#844)Pierre Neidhardt
2017-02-09[zsh] Do not cd when cancelling alt+c keybind (#840)Daniel Gray
2017-01-26Use --bind instead of --toggle-sortJunegunn Choi
Related #822
2017-01-21[zsh] Workaround trailing esacped space bug in go-shellwordsJunegunn Choi
https://github.com/mattn/go-shellwords/issues/3 Close #812
2017-01-17[shell] Do not override --reverse in CTRL-RJunegunn Choi
Close #807
2017-01-17[bash/zsh] Remove unused --reverse in CTRL-R bindingJunegunn Choi
Related #807
2017-01-15[shell] Make layout configurable via $FZF_DEFAULT_OPTS and $FZF_{KEY}_OPTSJunegunn Choi
2017-01-08Add --height optionJunegunn Choi
2016-12-24[shell] Use '-mindepth 1' to omit root folder in 'find' output (#779)Pierre Neidhardt
This removes the need for the 'sed' call. Faster, cleaner.
2016-11-15[shell] Fix pruning condition of find command for CTRL-T and ALT-CJunegunn Choi
`-fstype dev` is invalid. It's devfs on macOS and devtmpfs on Linux.
2016-07-11[zsh] Suppress error message when pipefail is not supportedJunegunn Choi
Close #615
2016-07-05[zsh] Re-initialize zle when widgets finishSebastian Reuße
zle automatically calls zle-line-init when it starts to read a new line. Many Zsh setups use this hook to set the terminal into application mode, since this will then allow defining keybinds based on the $terminfo variable (the escape codes in said variable are only valid in application mode). However, fzf resets the terminal into raw mode, rendering $terminfo values invalid once the widget has finished. Accordingly, keyboard bindings defined via $terminfo won’t work anymore. This fixes the issue by calling zle-line-init when widgets finish. Care is taken to not call this widget when it is undefined. Fixes #279
2016-06-16zsh: pass through exit code from widgetsDaniel Hahler
This allows to have a custom widget like the following, which would additionally accept the line, but only in case of entries being selected: fzf-file-widget-with-accept() { zle fzf-file-widget if [[ "$?" == 0 ]] && (( $#BUFFER )); then zle accept-line fi } zle -N fzf-file-widget-with-accept bindkey '\e^T' fzf-file-widget-with-accept With this `<C-a>t` will launch fzf, and simulate the pressing of "Enter" afterwards.
2016-06-12[shell] Add $FZF_CTRL_T_OPTS and $FZF_ALT_C_OPTSJunegunn Choi
Close #596
2016-06-08[bash/zsh] Fix $FZF_CTRL_R_OPTS with option values with spacesJunegunn Choi
2016-05-26[zsh] Fix #579 - Locally unset globsubstJunegunn Choi
2016-04-25[zsh] Fix issues with unicode charactersJunegunn Choi
2016-03-23Fix FZF_CTRL_R_OPTS for zsh (#526)Junegunn Choi
2016-03-23Add $FZF_CTRL_R_OPTS for overriding the default options for CTRL-RJunegunn Choi
Close #526
2015-11-09[zsh] Fix #404 - Escape $ in $LBUFFERJunegunn Choi
2015-11-08[shell] Add FZF_ALT_C_COMMAND for ALT-C (#408)Junegunn Choi
2015-11-05Not relying on exit status for CTRL-RJack Danger Canty
In the case that fzf-tmux returns a user-selected result but with a non-zero exit status (which can happen if a function inside $PS1 returns non-zero) this allows CTRL-R to continue working as expected. Addresses #203 (Tranquility's comment)
2015-11-04[zsh] fzf-history-widget - update local declarationJunegunn Choi