Maybe I'm just getting old, but I found most of the animations in this article to go too fast. I couldn't tell what was happening, couldn't tell what I was supposed to be looking at.
So you've installed `fzf` – now what?
221–230 of 292 posts
Re: So you've installed `fzf` – now what?
#222Earlier quoted context omitted.
Thank you!! Why on earth isn't that the default. It always seemed weird that with multiple bash windows open, the commands from most of them weren't added to the history.
It is very useful just be careful when switching between shells and hitting the up arrow to get the previous command, as you may get something from another shell.
Re: So you've installed `fzf` – now what?
#223Earlier quoted context omitted.
Thank you!! Why on earth isn't that the default. It always seemed weird that with multiple bash windows open, the commands from most of them weren't added to the history.
I often have three or more terminals open, doing different tasks in each; I also often have cycles of work where I'll repeat the last three commands again (three up-arrows and a return). This breaks if one terminal's commands get inserted into another terminal's history.
"Ted, the change I suggest doesn't affect the independence of your sessions as you suggest. Each shell maintains a unique history in memory so modifying the history file has no affect on running terminals. The only time the history file is read is when you start a new terminal. I recommend you try my suggestion. Really, all I am doing is eliminating the race condition that causes the bash history file to have inconsistent data.
Thanks for the feedback."
Re: So you've installed `fzf` – now what?
#224Dropping to say I miss your Twitter account man, I remember doing how-to-host-one-html.page years ago. Keep posting bangers king.
Re: So you've installed `fzf` – now what?
#225It tries to solve the "now what" part.
Re: So you've installed `fzf` – now what?
#226Maybe I'm just getting old, but I found most of the animations in this article to go too fast. I couldn't tell what was happening, couldn't tell what I was supposed to be looking at.
> Maybe I'm just getting old, but I found most of the animations in this article to go too fast. It's not that you're getting old and it's not that it's "too fast". The problem with many animations like this and why they make no sense whatsoever is because they cycle without adding a little pause... So you have no way to know when it's beginning and when it's ending. It's endemic on Github. Some .gif files are proper…
Re: So you've installed `fzf` – now what?
#227Surprised Ctrl+T didn't get a mention. Maybe that's a zsh-only thing, but it's basically the same as his vim $(fzf) example, except I only have to type vim and then Ctrl+T. I use this all the time when I'm running unit tests from the command line for instance. Helps me quickly get the path to the file I want without needing to remember the details of the folder structure. Just Ctrl+T -> tests/GLPage will yield me tes…
Re: So you've installed `fzf` – now what?
#228I really like the suggested command ` $(fzf)` to quickly open files in relative to the directory I am in. However, when I abort the fuzzy find with esc, it still opens without a file input, which is not what I want, so I wrote a little script for my shell config to prevent this: fuzz() { file=$(fzf) if [ ${#file} -gt 0 ]; then nvim "$file" # or any editor you prefer else : fi }
Re: So you've installed `fzf` – now what?
#229Fantastic article. I was exactly in the situation the article describes, I installed it, then, didn't find a use case. But that's because Ubuntu doesn't come with completion enabled by default. You have to add in your bashrc: if [ -e /usr/share/doc/fzf/examples/key-bindings.bash ]; then source /usr/share/doc/fzf/examples/key-bindings.bash fi The fzf and ubuntu docs don't mention you have to. Couldn't find easily how…
You do have to remember to use it, but the thing to keep in mind is that you can pipe a list of ANYTHING into it. Any list of text items you can search through with a text query is fair game. git log --oneline | fzf for example is one of my favorite tricks. Instead of scanning by eye or repeatedly grepping to find something, it's a live fuzzy filter. And depending on how deep you want to go you can then add key bindi…
git log --oneline | fzf | cowsay
Sky's the limit.Re: So you've installed `fzf` – now what?
#230have no need for this, plenty fast without it. these two have been sufficient for all my needs: ctrl + r for most things history | grep for searching when i forget the exact command or want to see related commands. I don't want pull downs, pull ups, drop downs, expanded hamburger menu, hot dogs, another set of key strokes to remember how i started some service last month.
vi $(fzf)
He claims to save a bunch of keystrokes by using it this way. But the string literal `vi $(fzf)` is saved in ~/.bash_history, not the actual filename. So you have to memorize the filename, AND deal with all those hamburgers and hot dogs, if you ever wanna re-edit that file after closing it.