freed-wu / fzf-tab-source Goto Github PK
View Code? Open in Web Editor NEW:gear: a collection of fzf-tab completion sources.
License: GNU General Public License v3.0
:gear: a collection of fzf-tab completion sources.
License: GNU General Public License v3.0
Image shows bat output on bottom pane for the same file being previewed and truncated in the top pane.
I'm using your ~/.lessfilter and kitty. Here are some environmental variables and options I think may be relevant
LS_OPTIONS=-N --color=tty -T 0
LESS=-r -M -r -M --mouse -S -I
LESSOPEN=|/usr/bin/lesspipe.sh %s
LESSQUIET=1
PAGER=less
FZF_DEFAULT_OPTS=--cycle --layout=reverse --height=90% --preview-window=wrap --scroll-off=3 --bind tab:down,shift-tab:up
bat config =
--color='always'
--theme='Coldark-Dark'
--style=plain
--pager=less
--wrap=character
Running openSUSE Tumbleweed with lesspipe installed from source and using zcomet with these plugins
Plugins:
3v1n0/zsh-bash-completions-fallback
aubreypwd/zsh-plugin-require
Freed-Wu/fzf-tab-source
Freed-Wu/zsh-colorize-functions
Freed-Wu/zsh-completions-for-cross-compilers
Freed-Wu/zsh-help
jdujava/fzf-tab-jd
Licheam/zsh-ask
mdumitru/last-working-dir
microsoft/inshellisense
zdharma-continuum/fast-syntax-highlighting
zpm-zsh/colorize
zpm-zsh/ssh
zsh-users/zsh-autosuggestions
FPATH elements:
corvofeng/joe-completion
grigorii-zander/zsh-npm-scripts-autocomplete
MenkeTechnologies/zsh-more-completions
nix-community/nix-zsh-completions
sainnhe/zsh-completions
sambergo/zsh-prettier-completion
syohex/zsh-misc-completions
Is it possible to get the current width and hight of the preview box ?
I am trying to make timg work with this but it requires the current width and height of the terminal.
tput and the env variables ($LINES etc) point to the actual terminal, while stty fails.
Hi! I only want to enable several plugins, not all of them.
Please, provide a way (similar to plugins=()
in .zshrc
) to do that :)
Can you help me understand why it won't work?
I only get previews for certain files like text files. For most others, like directories I get:
Also for text files it uses cat
, not bat
I tried installing from the AUR and also pulling from the repo directly.
These are the relevant lines in my .zshrc
. I tried disabling many of them without success.
_fzf_compgen_path() {
fd --hidden --follow --exclude ".git" . "$1"
}
# Use fd to generate the list for directory completion
_fzf_compgen_dir() {
fd --type d --hidden --follow --exclude ".git" . "$1"
}
[ -f /usr/share/fzf/completion.zsh ] && . /usr/share/fzf/completion.zsh
[ -f /usr/share/fzf/key-bindings.zsh ] && . /usr/share/fzf/key-bindings.zsh
[ -f ~/.fzf-tab-source/fzf-tab-source.plugin.zsh ] && . ~/.fzf-tab-source/fzf-tab-source.plugin.zsh
[ -f ~/.fzf-tab/fzf-tab.plugin.zsh ] && . ~/.fzf-tab/fzf-tab.plugin.zsh
zstyle ':fzf-tab:*' fzf-bindings 'ctrl-space:toggle+down'
This is a relevant line in my .zprofile
export FZF_DEFAULT_OPTS="--bind=tab:down,shift-tab:up,ctrl-space:toggle+down"
I also tried removing it and rebooting.
Check the installation documentation...but I still don't understand...
.zshrc
configfile I have these
zinit light Aloxaf/fzf-tab
zinit light Freed-Wu/fzf-tab-source
source /home/user/.local/zinit/plugins/Freed-Wu---fzf-tab-source/sources/*.zsh
Then I deleted some of my settings.
eg:
zstyle ':fzf-tab:complete:cd:*' fzf-preview 'eza -1 --color=always $realpath'
But I didn't feel any change.
Preview gallery
Note: if you don't want to spend time to write these configs by yourself, you can try this zsh plugin.
what steps did I take wrong?
or, I understood it wrong, I still need to configure fzf-tab manually, right?
I'd appreciate a response. thanks🙏
Thanks for the amazing plugin.
Please do not create empty directories by default.
Empty file within directory under $HOME/.gitmoji/
is created irrespective of whether program is installed or not.
May be you can just add a check to see if gitmoji
is installed before creating the directory
Right now, it seems like brew commands do not have a preview.
from the fzf-tab wiki, this does work:
zstyle ':fzf-tab:complete:brew-(install|uninstall|search|info):*-argument-rest' fzf-preview 'brew info $word'
maybe consider adding it ?
After I updated less, this plugin cannot work. I am finding reason. In another PC with less 608, it works normally.
[2023-05-17T23:22:43+0800] [ALPM] upgraded less (1:608-2 -> 1:633-1)
Top level completions like this:
dont show a preview, while when it is a subcommand like this:
it works perfectly fine !
My lessfilter: lessfilter.txt
Hello,
I was trying to use this and the instructions don't actually say how to install this. A line saying to source the fzf-tab-source.plugin.zsh
would be helpful. (Maybe this would be automatically done with plugin managers, but I don't use any..?).
Thanks!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.