0

I was learning rust. I am building a simple GUI application that scrapes through aur and installs a package. I am using tauri for GUI.

So, to install an aur application, I will run makepkg -si inside the package directory. But, it asks for root password in the middle of installation. After searching web, I came to know, I can use pkexec to ask password graphically but pkexec is like using sudo and running makepkg as sudo is not allowed.

Any idea of what should I do? Are there any articles where I can look into ?

2 Answers 2

0

So, to install an aur application, I will run makepkg -si inside the package directory. But, it asks for root password in the middle of installation. After searching web, I came to know, I can use pkexec to ask password graphically but pkexec is like using sudo and running makepkg as sudo is not allowed.

makepkg itself uses sudo when necessary. It never asks you for a password directly; it just calls sudo or doas when it has to invoke pacman.

So if sudo is being used, you can e.g. set the SUDO_ASKPASS environment variable to some program that would display the password prompt.

You can also set PACMAN_AUTH through your ~/.config/pacman/makepkg.conf to have it use pkexec instead.

-1

Usage of graphical AUR helpers may lead to a defective system, for example through unattended partial upgrades. That being said, I would recommended looking at paru being a rust aur helper to get to know how to make/use a aur helper in rust

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.