0

I am new to Ubuntu. On Windows, for the command line, I have been using this great little CLI tool called Clink, which (https://mridgers.github.io/clink/), which remembers past commands and also suggests commands based on the commands available from your path. When writing a line, it shows in transparent letters the statement that you possibly want to write, and you can simply hit right arrow to complete it. This saves a lot of time. On Ubuntu, I just found the tab-completion (but without transparent suggestions) and of course hitting arrow up to scroll through past commands. But I am sure there must be something like clink installable for ubuntu, as well, right? What are your suggestions? Thanks!

2 Answers2

1

When on the command line enter ctrl+R then start typing your command and it will autocomplete using your command history. See more details here:

eli
  • 173
1

There is the "build-in" history search using Ctrl+R. Hit Ctrl+R, start typing part of the previous command, and it will search matches.

Fuzzy finder, fzf, provides such functionality, but on steroids. Type something, hit Ctrl+R and a list of matching commands will immediately be displayed, which you can select and execute when hitting Enter.

enter image description here

Install fuzzy finder with the command sudo apt install fzf and add the line

source /usr/share/doc/fzf/examples/key-bindings.bash

to your ~/.bashrc file to enable integration with fzf.

To be complete here, you can also add

source /usr/share/doc/fzf/examples/completion.bash

to have a command autocomplete feature provided by fzf.

vanadium
  • 88,010