I occasionally need to know the names of programs. I asked here about "Run as Administrator" being added to the context menu (like in Windows), and the response was basically "can't be easily done". an example is if I wish to edit a config file it cannot be done without accessing the terminal. Knowing the name "gedit" is the real name of "text editor" is useful information in this use-case.
I am not afraid of the terminal, but I would never prefer it over a GUI. is there a way to find a program name/install location from right-clicking-details (or something)? So then I could open a terminal and "sudo programname"?
(As an aside, I prefer Linux overall, but every distro I've tried has a strong sense that if you're using the GUI you don't need or deserve admin controls. Program names in the menus are almost always different from their names in the terminal, and many what I would consider normal system settings, like the ability to act as an administrator, find where a program is installed are terminal only.)
This is Ubuntu with all the default stuff
EDIT: I always expect a degree of hostility and talking-down from the desktop Linux community, but the number of people in this thread telling me I am using my own computer that I bought with my own money in a way they don't prefer while ignoring my question is just absurd and frankly should be deeply embarrassing for all of us. I have strongly defended the desktop Linux community for decades, but this experience has left a sour taste in my mouth.
Thank you to the few of you who tried to assist without judgement or assumptions.
Use bash-completion, it is much faster than clicking menus.
every distro I’ve tried has a strong sense that if you’re using the GUI you don’t need or deserve admin controls
GUI tools are not suited to be run as root in general. Few ones that are have special measures taken to prevent gaining privileges by another process, e. g. run a background non-GUI process as root and GUI communicating with it as an ordinary user. Such tools (package managers, system tweakers etc.) are usually configured to get required privileges via polkit (e. g.
pkexec synaptic
to run GUI package manager in Debian). Don't usesudo
to run GUI programs!Thank you for the advice I will take it under consideration.You seem educated in this area, do you know of an easy way to identify the real name of a program without the terminal?
https://github.com/brunonova/nautilus-admin
This is unmaintained, so it may not work with the latest ubuntu, but it is an extension to the default ubuntu file manager that does some of what you want
As for your title question, unfortunately ubuntu/gnome don't seem to make this easy. On some DEs you can just right click and go find the shortcut properties sorta like on windows. Others have noted some good reasons why GUI apps shouldn't run as root, but you're right that sometimes it's necessary, or simply the easiest/most expedient way to do things.
You can accomplish what you ask using a little shell script though, which you could bind to a keyboard shortcut or something. I may elaborate further but basically:
readlink /proc/"$( xprop _NET_WM_PID | sed 's/_NET_WM_PID(CARDINAL) = //')"/exe
and then clicking on the window you want to ID will attempt to identify the binary it's running. then you could either display it in a popup using zenity, or write it directly to the clipboard using xclip (or wl-copy I think for wayland distros)
I really like setting up little shortcut scripts like this with zenity for user input, and usually the notification tray or clipboard for output
I understand your pain. Most things you need to configure are either in your home direct under .config or they prompt for admin if they need it. However, not everything has a convenient gui interface to make config changes. This is mostly ok because configuration is usually done once and then never touched again.This is how Linux works, it just isn't a like for like replacement for windows, though it can achieve the same goals.
I like a better gui for adjusting audio devices, specifically the sample and bit rates. I haven't found anything that can do it in a straightforward gui.
From this and your other thread I’m getting the idea that you should switch desktop environments. Gnome doesn’t provide that functionality in the context menu by default and tends to obfuscate program names in order to be more straightforward.
Install kde. See how it treats you. It’s a lot more windowsy than gnome.
Usually when gnome users run into something they can’t do with the gui they’ll either go without it or use the command line to do it. That’s the way macos users are too.
If you don’t wanna use the command line you gotta have a de that doesn’t treat it as an acceptable fallback.
I’m just gonna respond to your other thread here as well. The problem you ought to be trying to solve isn’t running a gui program sudo (which is a bad idea for all the reasons everyone else in that thread listed), but why you’re not being prompted for credentials when you try to do something that needs them.
One of the examples you gave is a network share file access and it could be (I’m guessing because decades ago I did this too) that you have admin credentials on your local machine that match the ones your network share is looking for. If that’s the case, it’s bad, fix it.
It’s a lot more windowsy than gnome.
Is it as easily customizable now? The thing I hate about Windows and love about GNOME is that I can configure the UI to look like almost anything with a few clicks and there is a great community creating great extensions. I haven't tried KDE in many years but I found it more limiting than even Windows last time I tried it.
I don’t know what you want to customize, but it seemed really customizable to me.
So you understand who you’re talking to: I use lxqt and the only customized thing about it is taskbar on the left side of the screen.