Score:2

How to install .deb package with double click

es flag

I'd like to install .deb packages I download from the internet, (ie google chrome or discord) from nautilus by just double clicking (the way it works in windows). I used to use gdebi, but it opens a gui panel, which annoys me personally so I removed it. Is there any way to do this by shell script or install some package that does it for me?

To be clear, I have root access on my machine, I can change arbitrary files and can run any scripts as "sudo." I just want to be able to install .deb packages in nautilus by double-clicking, instead of having to open a terminal.

I realize the security implications of this, but I only download packages I trust and have nothing valuable on my computer so I would like a way to save the 30 seconds.

cn flag
Ray
I think you should keep in mind one difference between Windows and Ubuntu. With Windows, if you're able to install it "just by double clicking", most likely you have a system administrator's account. With Ubuntu, you have a normal account and you gain administrator's privilege by using `sudo` with your password. You never log into a Linux system with administrator's access already "on". Thus, with Linux, it's expected you'll need a few more steps compared to Windows.
grand aneww avatar
es flag
Could I add a shell script with admin privileges that listens for my clicks in nautilus and runs dpkg -i <packagename> and then sudo apt -f though?
cn flag
Ray
You're asking to bypass the authentication stage for `sudo`, but Linux is a multi-user system. Windows originally (and, in a way, still is) a single-user system -- it can assume whoever logs in is an admin, by default. So, I would say "no", but perhaps someone else knows more than me and can help you with this. I think it's better to understand that Linux and Windows are different, instead of trying to force one to "emulate" the other.
grand aneww avatar
es flag
That's not needed, I can run sudo on the script just fine. Since it's possible for gdebi to do it, I thought there might be someone who'd be able to point me to some documentation for nautilus API or reflecting gdebi methods in python.
Score:0
cn flag

Apt can do it. Apt will figure out dependencies, too.

sudo apt install /path/to/downloaded.deb

Or dpkg can do it. Dpkg won't figure out dependencies.

sudo dpkg --install /path/to/downloaded.deb
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.