fzf is a serious timesaver. To be able to quickly go through past commands and in a fuzzy manner, especially when you don’t recall the exact command is a Godsend!

To install fzf on Linux, we need to

a) clone the repository into the system

git clone --depth 1 https://github.com/junegunn/fzf.git ~/.fzf

b) run the command which will add the relevant shortcut keys

~/.fzf/install --all

There are a bunch of other stuff that can be done once fzf is installed. For example, to see instant file previews –

fzf --preview 'less {}'

And if there is bat also installed, then the previews can show syntax highlighting and line numbers also!

fzf --preview 'bat --color=always --style=numbers --line-range=:100 {}'