Comments (12)
I made an exact search for fzf for yourself as a temporary solution in the absence of the functionality that I talked about in this issue.
from fzf-tab.
Tell me where in the code the command line arguments are fetched?
from fzf-tab.
Sorry for the late reply.
In fact, fzf-tab used to behave as you expect. But I found it is inconsistent with the default behavior of zsh's interactive search.
To be consistent with zsh, and to improve performance, I changed the list order.
Since this behavior is the same as zsh, I will still keep this as the default. But I'd like to add an extra variable like FZF_TAB_NO_SORT
for the behavior you expect. What do you think?
from fzf-tab.
Yes, that would be great.
It will be for everything or only for arguments?
from fzf-tab.
For everything.
It will mess some results like completion of variable name.
Ummm, need a better way to solve this.
from fzf-tab.
This can only be done for arguments?
I decided this by quickly switching the sort: bindkey '^S' toggle-sort-fzf-tab ## Ctrl+S
toggle-sort-fzf-tab() {
if [[ ${FZF_TAB_SORT} == 1 ]]; then
FZF_TAB_SORT=0
else
FZF_TAB_SORT=1
fi
}
and created a PR
toggle-sort-fzf-tab works visually but when disabling sorting, arguments are not selected. ๐
from fzf-tab.
It's still under development. I need a better way to meet the needs of different people.
I'm considering switching fzf-tab's configuration from variables to zstyle so that it can be more flexible.
eg.
zstyle ':completion:fzf-tab:-parameter-' sort true
zstyle ':completion:fzf-tab:*:' sort false
from fzf-tab.
While sorting is not solved with fzf-tab, I adapted two plugins.
## fzf-tab
bindkey '^[[Z' fzf-tab-complete ## Shift+Tab
## fzf-tab-completion
bindkey '^I' fzf_completion ## Tab
from fzf-tab.
How are you doing with the development?
from fzf-tab.
Please check #46
You can now set zstyle ':fzf_tab:*:options' sort false
to just disable sorting when completing options.
from fzf-tab.
I do not understand how to apply it zstyle ':fzf_tab:*:options' sort false
Even if I just put zstyle ':fzf_tab:*:options' sort false
this does not work, the arguments are not selected!
from fzf-tab.
Here the bug is fixed, everything works.
Added sorting switch, so much more convenient:
....
disable-sort-fzf-tab() {
typeset -g _ZSH_FZF_TAB_SORT
emulate -L zsh
zstyle ':fzf_tab:*' sort false
}
enable-sort-fzf-tab() {
unset _ZSH_FZF_TAB_SORT
emulate -L zsh
zstyle ':fzf_tab:*' sort true
}
sort-fzf-tab() {
if [[ -n "${_ZSH_FZF_TAB_SORT+x}" ]]; then
enable-sort-fzf-tab
else
disable-sort-fzf-tab
fi
}
enable-fzf-tab
zle -N toggle-fzf-tab
zle -N sort-fzf-tab
....
In .zshrc
....
## toggle sort in fzf-tab
bindkey '^S' sort-fzf-tab # Ctrl+S
....
from fzf-tab.
Related Issues (20)
- Ctrl J-K movement [Q] HOT 1
- [BUG] Syntax highlighting disappears when completion is cancelled HOT 2
- [Q] Error when using fzf-tab's preview feature HOT 10
- [Q] How can I let fzf-tab use these configs I set for fzf HOT 1
- [BUG] Breaks nix completion when quotes are used instead of \ HOT 2
- [Q] why my completion is like this
- [FR] Add support for zellij floating panes
- [BUG] build-fzf-tab-module fails with "conflicting types for โboolcodesโ" HOT 1
- [Q] Is there way to set the height of the preview window? HOT 2
- build-fzf-tab-module fails on MacOs(14.5) because of helpfiles?
- [BUG] Using `--tmux` in an exported `FZF_DEFAULT_OPTS` breaks `ftb-tmux-popup` HOT 6
- [BUG] Completion options are not shown when word starts with a quote
- [Q] Color syntax of completion selection menu cannot be displayed normally HOT 1
- [BUG?] Do not select a candidate when pressing the slash (/) key HOT 1
- [Q] What's the difference between this plugin and the offical fzf implementation? HOT 2
- [BUG] Preview always shows "fork/exec /usr/bin/zsh: invalid argument" HOT 5
- [Q] How to make fzf-tab show all available completion values HOT 1
- fzf-tab hl color setting does not take effect HOT 2
- [BUG] delay in autocomplete with WSL1
- [BUG] `cd` completion bug when a folder start with digit
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from fzf-tab.