Install and Use Linuxbrew on Ubuntu 20.04 LTS Linux system

Linuxbrew is the fork or clone of the Homebrew package manager that is compatible with both macOS and Gnu / Linux. Homebrew is the package manager for macOS which can be used to install the different packages in your home directory without using the root privilege. As Linuxbrew is a clone of Homebrew so syntax to use Linuxbrew is the same as Homebrew.

Here at LinuxAPT, as part of our Server Management Services, we regularly help our Customers to perform related Linux system Configuration queries.

In this context, we shall look into how to install and use the Linuxbrew on Ubuntu 20.04 LTS system.

How to install Linuxbrew on any Linux Distribution ?

Before installing Linuxbrew you need to install a few essential packages as Linuxbrew is installed on many Linux systems through the script.

For Debian or Ubuntu,

$ sudo apt update
$ sudo apt install build-essential curl file git

For Fedora, CentOS, or Red Hat,

$ sudo yum groupinstall 'Development Tools'
$ sudo yum install curl file git

Now use the following command to download and run the script to install Linuxbrew:

$ sh -c "$(curl -fsSL"

How to set up Environment Variable for Linuxbrew ?

Once the installation script installs the Linuxbrew, you need to set up the path for the Linuxbrew in order to be able to use it on your terminal. So, to do so run the following command in your terminal:

$ echo 'export PATH="/home/linuxbrew/.linuxbrew/bin:$PATH"' >>~/.profile
$ echo 'export MANPATH="/home/linuxbrew/.linuxbrew/share/man:$MANPATH"' >>~/.profile
$ echo 'export INFOPATH="/home/linuxbrew/.linuxbrew/share/info:$INFOPATH"' >>~/.profile

Then, apply the changes using the following command:

$ source ~/.profile

Now, you can install the different packages maintained by the brew community in the following way:

$ brew install package_name

How to use Linuxbrew ?

In order to know how Linuxbrew works, run the following command:

$ brew --help

For the manual which provides the details info on it run:

$ man brew

For checking the installation of Linuxbrew run:

$ brew doctor

If you have no idea what package you want to install is available or not on Linuxbrew run:

$ brew search package_name

Use the following commands to update and upgrade the packages:

$ brew update
$ brew upgrade

For removing the installed packages you need to run the command in the following way:

$ brew remove package_name

[Need help in fixing Linux system Software Installation issues ? We can help you. ]

This article covers how to install Brew on Ubuntu 20.04 LTS Linux. In fact, Homebrew is one of the popular package managers for Mac OS X but can be installed on Linux as well to download and install various packages. Homebrew Cask extends Homebrew with support for quick installation of applications like Google Chrome, VLC, and more.

Basically, you can use the brew command to install the third-party package that maintains the brew community. 

Related Posts