How to Install Yay AUR Helper in Arch Linux and Manjaro

The tow commonly used AUR helpers in Arch Linux are Yaourt and Packer. You can easily use them for Arch Linux package management tasks such as installing and updating packages.

However, the two have been discontinued in favour of yay, short for Yet Another Yaourt. Yay is a modern AUR helper written in the GO language. It has very few dependencies and supports AUR tab-completion so that you don’t have to type the commands in full. Just type the first few letters and hit ENTER.

In this article, we demonstrate how you can install Yay AUR helper on Arch Linux or Manjaro which is based on Arch and see a few examples of how you can use Yay.

Installing Yay AUR Helper in Arch Linux and Manjaro

To start off, log in as a sudo user and run the command below to download the git package.

$ sudo pacman -S git
Install Git on Arch Linux

Install Git on Arch Linux

Next, clone the yay git repository.

$ cd /opt
$ sudo git clone https://aur.archlinux.org/yay-git.git
Clone Yay Git Repository

Clone Yay Git Repository

Change the file permissions from the root the sudo user.

$ sudo chown -R tecmint:tecmint ./yay-git
Set Permissions on Yay AUR Helper

Set Permissions on Yay AUR Helper

To build the package from PKGBUILD, navigate into the yay folder.

$ cd yay-git

Next, build the package using the makepkg command below.

$ makepkg -si
Install Yay AUR Helper in Arch Linux

Install Yay AUR Helper in Arch Linux

How to Use Yay in Arch Linux and Manjaro

Once you have yay installed, you can upgrade all the packages on your system using the command.

$ sudo yay -Syu

To include development packages during the upgrade run.

$ yay -Syu --devel --timeupdate

As with any other AUR helpers, you can install the packages using the command.

$ sudo yay -S gparted

To remove a package using yay use the command.

$ sudo yay -Rns package_name

To clean up all unwanted dependencies on your system, issue the command.

$ sudo yay -Yc

If you want to print system statistics using yay, run.

$ sudo yay -Ps

And this sums up this brief tutorial on how you can install the yay AUR helper in Arch Linux and Manjaro.

If You Appreciate What We Do Here On TecMint, You Should Consider:

TecMint is the fastest growing and most trusted community site for any kind of Linux Articles, Guides and Books on the web. Millions of people visit TecMint! to search or browse the thousands of published articles available FREELY to all.

If you like what you are reading, please consider buying us a coffee ( or 2 ) as a token of appreciation.

Support Us

We are thankful for your never ending support.

James Kiarie

This is James, a certified Linux administrator and a tech enthusiast who loves keeping in touch with emerging trends in the tech world. When I'm not running commands on the terminal, I'm taking listening to some cool music. taking a casual stroll or watching a nice movie.

Your name can also be listed here. Got a tip? Submit it here to become an TecMint author.

RedHat RHCE and RHCSA Certification Book
Linux Foundation LFCS and LFCE Certification Preparation Guide
The Complete Linux System Administrator Bundle
Become an Ethical Hacker Bonus Bundle

You may also like...

6 Responses

  1. Herfen says:

    Yeah good guide but there’s a Typo /yay-git is yay actually.

    • Matt says:

      yay‘ is for releases, whereas ‘yay-git‘ is the package for the git upstream repo.

      This is a standard AUR convention.

      The typo is putting the forward-slash before the directory name in the chown command.

      $ sudo chown -R tecmint:tecmint /yay-git
      

      should be:

      $ sudo chown -R tecmint:tecmint ./yay-git
      

      or just

      $ sudo chown -R tecmint:tecmint yay-git
      
  2. MarkDubya says:

    DO NOT use sudo with yay. Pacman will prompt for privileges as needed.

    FYI, yay is in the Manjaro community repo and can be installed with:

    $ sudo pacman -S yay 
    Or
    $ pamac install yay
    

Got something to say? Join the discussion.

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.