Bash Auto Completion in Alma Linux 9

In this article, we cover Bash Auto Completion feature in AlmaLinux 9. Command-line completion basically makes a user-friendly interface. We don’t have to remember and enter commands all the time. With this feature, all we have to do is enter first few characters and press TAB. This would show us a list of suggestions which we could be interested in.

And, this isn’t just limited to commands. It would work even for filenames, directory names etc. This saves us both time and effort.

Recently, we started using AlmaLinux. And, immediately we noticed that Bash Auto Completion feature wasn’t available. Bash auto completion feature can be enabled through bash-completion package, which we cover next.

Note: Following operations require superuser privileges. In case you don’t have one then, we advise you to contact your System Administrator for assistance.

Bash Auto Completion in AlmaLinux 9

As already covered, we have to install bash-completion package. We will be using dnf package manager. So, open a terminal and issue the following –

# dnf install bash-completion

It prompts us whether we are Ok installing the package, press y to install. Once installed it would show Complete! message.

Now, either open a new terminal or just logout to check if Bash Auto Completion feature is working for you or not.

In conclusion, we have covered how to enable Bash Auto Completion feature in AlmaLinux 9.

Additional Info –

After we issue the following command –

# dnf install bash-completion

It shows us package related info, which in this case is about bash-completion. Notice that, the package is part of BaseOS repository. But, not all packages we may install in future would be a part of BaseOS repository. There are other repositories like EPEL, which have numerous packages as well as their dependencies available. Wherever required, we will cover that part as well.

Similar Posts