-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
[fzf] Bat is awesome, but #357
Comments
Because we want
You can do this. You just have to explicitly enable colors and/or decorations. Please study the Also, make sure to use export FZF_DEFAULT_OPTS="--ansi --preview-window 'right:60%' --preview 'bat --color=always --style=header,grid --line-range :300 {}'" Please let me know if this works for you. |
Oh, that's so cool! Sure it works. I'll add |
Awesome 👍 Shameless advertising of another project of mine: You can also integrate Instructions are here: https://github.com/sharkdp/fd#using-fd-with-fzf I use the |
Yeah, your |
Fantastic! 😍 |
I do use |
Yes, of course!
|
ugh oh, seems that my agents provide outdated info... Anyway, bug thanks for your great tools! |
Can we tell bat to highlight a pattern passed as command line argument? Currently, using interactive LESS style search ( |
@MoezGholami If you're looking for a way to highlight lines that match some pattern, you might be able to borrow some ideas from batgrep? If you're specifically looking for a way to highlight a line which matches a pattern specified through a command line argument, I would definitely say to open a feature request for it. |
@MoezGholami Is this similar to what you have in mind?
(Thanks to @ahmedelgabri for showing me |
@dandavison Thanks man, that's exactly what I want. @eth-p and @ahmedelgabri , thank you too. |
for people who are on a quest to make a preview with bat AND tree when it is a directory after painful trial and error here it is:
|
@dagadbm I think this can be slightly simplified, you don't need the export FZF_PREVIEW_COMMAND="bat --style=numbers,changes --wrap never --color always {} || cat {} || tree -C {}"
export FZF_CTRL_T_OPTS="--min-height 30 --preview-window down:60% --preview-window noborder --preview '($FZF_PREVIEW_COMMAND) 2> /dev/null'" |
it works like that for you? i tried that before and he always printed both things. |
It would be great if you could post your findings/scripts/solutions in #448. We are still lacking a |
It's so awesome, but whyyyyy
I wanted to use
bat
instead ofhighlight
in fzf, since it can usecat
for previewing files, but this line kills the usage for me unfortunately. I don't usecat
as standalone app at all, but as embedded one, and it's unfortunately that fzf treated as non-interactive terminal, however it supports scrolling. Or maybe I should open issue on fzf side?The text was updated successfully, but these errors were encountered: