summaryrefslogtreecommitdiff
path: root/shell/completion.bash
AgeCommit message (Collapse)Author
2020-03-07[completion] Use file redirection instead of pipeJunegunn Choi
This change allows the completion system of bash and zsh to return before the input process completes. Related #1887
2020-02-20[bash] Strip trailing whitespace on kill completionJunegunn Choi
2020-02-20[completion] Allow users to customize fzf options via _fzf_comprunJunegunn Choi
Related #1809 #1850
2020-02-19[bash-completion] Minor optimizationJunegunn Choi
2020-02-17Make pointer and multi-select marker customizable (#1844)Hiroki Konishi
Add --pointer and --marker option which can provide additional context to the user
2019-12-20[bash-completion] Fix default alias/variable completionJunegunn Choi
Fix #1795
2019-12-06[ssh completion] Skip only aliases matching * (#1788)Henré Botha
This commit fixes a bug where lines that declare multiple hostnames get omitted from completion entirely if one of the hostnames matches *. For example: Host foo.com bar.dev baz.*
2019-12-06[completion] Add support for HostName lines in ~/.ssh/config (#1785)David Gray
Close #1783
2019-12-05[completion] Ignore hg repos (#1777)John Purnell
* Update completion.bash * Update completion.zsh
2019-09-29[bash-completion] Properly handle exit eventJunegunn Choi
Related #1704
2019-08-09[bash-completion] _fzf_setup_completion to retain previous optionsJunegunn Choi
2019-08-08[bash-completion] Add _fzf_setup_completion to enable fuzzy completionJunegunn Choi
While we can attach `_fzf_path_completion` or `_fzf_dir_completion` to any command using the standard bash complete command, the functionality of the existing completion function is lost. Use _fzf_setup_completion if you want to extend the existing function with fuzzy completion instead of completely replacing it. e.g. _fzf_setup_completion path kubectl
2019-05-01[bash-completion] Fix custom completion with dynamic loader enabled for ↵Jesus Briales
non-standard command names (#1564) Related to #1170. Fix the solution for commands with non-standard names where `$cmd` and `$orig_cmd` differ. e.g. `s.foo` -> `s_foo`
2019-02-28[completion] Look up on ~/.ssh/config.d/* files when doing ssh host complete ↵Rui Coelho
(#1420)
2019-02-28[shell] Skip loading completion code on non-interactive shellJunegunn Choi
This change is not required if you use the install script to generate ~/.fzf.bash or ~/.fzf.zsh which already has the proper guard statement. Close #1474
2018-07-06[completion] Filter out non-hostnames in SSH config file (#1329)Jay
* Correctly exclude SSH config options with Host SSH config files have 14 options containing 'Host'. Previously The zsh and bash completion scripts would include lines containing these options when doing command-line completion of SSH hosts with `ssh **`. This commit fixes that problem by only including lines with 'host '. * Don't autocomplete SSH hostnames using ? SSH config files support ? as well as * for wildcards in Host lines. This commit excludes lines containing ? for zsh/bash command line completeion using `ssh **`
2018-06-02[bash/zsh] Fix missing fuzzy completions (#1303)ptzz
* [bash/zsh] Fix missing fuzzy completions `cat foo**<TAB>` did not display the file `foobar` if there was a directory named `foo`. Fixes #1301 * [zsh] Evaluate completion prefix cat $HOME** cat ~username** cat ~username/foo**
2018-05-04[bash] Do not print error when falling back to default completion (#1279)ptzz
Fixes #1278
2018-04-30[bash] Fix infinite loop on tab completionJunegunn Choi
awk may not set OFS to match FS depending on the implementation. Close #1227
2018-04-12ZSH and Bash completion: remove shebang (#1248)Avindra Goolcharan
Shebangs are only for files that are directly executable. In cases where files are only sourced (such as completion scripts), these are unneeded.
2018-02-15[bash] Fix extra space issue of dynamic completion with 'nospace'Junegunn Choi
Close #1203
2017-12-03[bash-completion] Fix custom completion with dynamic loader enabledJunegunn Choi
After _completion_loader is called, instead of loading the entire completion.bash file, just restore the fzf completion for the current command. `_fzf_orig_completion_$cmd` is only set if _completion_loader actually changed the completion options to avoid infinite loop. Close #1170
2017-10-21[completion] Ensure ps called as command (#1098)Igor Urazov
When `ps` is aliased for something uncommon, like `alias ps=grc ps` which colorizes ps output, the output of `ps` can be unexpected and/or undesired. This change makes ps to be always executed as command, even if it's aliased.
2017-10-19[completion] Fix known_hosts completion for custom port number (#1092)Andrey Chernih
Handles records like "[20.20.7.168]:9722 ssh-rsa ..." This is a standard format for servers running on custom port according to http://man.openbsd.org/sshd.8#SSH_KNOWN_HOSTS_FILE_FORMAT A hostname or address may optionally be enclosed within ‘[’ and ‘]’ brackets then followed by ‘:’ and a non-standard port number.
2017-09-27[completion] Include host aliases in ssh completion (#1062)Josh Pencheon
2017-07-31Revert "[bash] Do not append space when path completion is cancelled"Junegunn Choi
This reverts commit 376a76d1d3c39a1686b6ac7a6118c1f80af3178e as it affects normal completion
2017-07-30[bash] Do not append space when path completion is cancelledJunegunn Choi
Close #990
2017-04-11[bash-completion] Use -o dirnames instead of -o plusdirsJunegunn Choi
Close #903 Related #135
2017-03-21Add support for IPv6 addresses in ssh completion (#877)Sam Van Den Berge
Signed-off-by: Sam Van Den Berge <sam@drgt.net>
2017-01-15[completion] Restore --height option for kill completionJunegunn Choi
2017-01-15[shell] Make layout configurable via $FZF_DEFAULT_OPTS and $FZF_{KEY}_OPTSJunegunn Choi
2017-01-15[completion] Add preview window to kill completionJunegunn Choi
2017-01-15Replace --normalize with --literal and enable normalization by defaultJunegunn Choi
Ref #790
2017-01-14Fix $FZF_COMPLETION_OPTS evaluationJunegunn Choi
Close #799
2017-01-08Add --height optionJunegunn Choi
2017-01-07[bash/zsh-completion] Filter ~/.ssh/known_hostsJunegunn Choi
Close #791
2016-12-31[bash-completion] Always backup existing completion definitionsJunegunn Choi
_fzf_completion_loaded is no longer checked. This change increases the load time by a few milliseconds, but I can't think of a better way to handle the issue. Close #783.
2016-09-24Fix #668Maverick Woo
Handle uppercase letters in program names. This also deals with `-` and `.`, both of which are quite common in program names, e.g., `xdg-open` and `foo.sh`.
2016-07-07[shell] Suppress alias/function expansionJunegunn Choi
Close #611
2016-06-02[bash/zsh] Take SSH completion hints from known_hostsJim Howell
Signed-off-by: Junegunn Choi <junegunn.c@gmail.com>
2016-04-23Update completion.bashGene Pavlovsky
Fixes #548. Avoid using a subshell in _fzf_defc().
2016-03-02[bash] Fix shellcheck warningsJunegunn Choi
Close #516
2016-02-070.11.3Junegunn Choi
2016-01-29[completion] _fzf_complete_COMMAND_post for post processingJunegunn Choi
e.g. _fzf_complete_foo() { _fzf_complete "--multi --reverse --header-lines=3" "$@" < <( ls -al ) } _fzf_complete_foo_post() { awk '{print $NF}' } [ -n "$BASH" ] && complete -F _fzf_complete_foo -o default -o bashdefault foo
2016-01-20Make fuzzy completion customizable with _fzf_compgen_{path,dir}Junegunn Choi
Notes: - You can now override _fzf_compgen_path and _fzf_compgen_dir functions to use custom commands such as ag instead of find for listing completion candidates. - The first argument is the base path to start traversal - Removed file-only completion in bash, i.e. _fzf_file_completion. Maintaining a list of commands that only expect files, not directories, is cumbersome (there are too many) and error-prone. TBD: - Added $FZF_COMPLETION_DIR_COMMANDS to customize the list of commands which use directory-only completion. The default is "cd pushd rmdir". Not sure if it's the best approach to address the requirement, I'll leave it as an undocumented feature. Related: #406 (@thomcom), #456 (@frizinak)
2015-12-28Fix autocompletion for absolute pathsKobe Lipkens
2015-12-29[bash/zsh-completion] List hidden files as wellJunegunn Choi
Close #456 and #457
2015-11-12[bash-completion] Fix #417 - Update command listJunegunn Choi
2015-11-06[bash-completion] Add nvim to f_cmdsLeandro Freitas
2015-11-03Make --extended defaultJunegunn Choi
Close #400