A common recommendation is not to run X as root. Reasonable advice but there are always exceptions to such advice. Life is not black and white. Where I work the owner wants users to have admin privileges. As an old proverb goes, this is not a hill I’ll defend. I don’t own the company. The computers are not my property. I inform the owner of the risks and caveats, but the final decision is not mine.
Users have been trained that logging into the root account in this way should be the rare exception. The users abide by that.
To help remind users I created a special background image:
This is an administrative account. Use this account only for local computer administrative tasks. Do NOT use this account for normal work flow tasks.
Should users log into the root account this way, I wanted to further discourage possible inappropriate usage, such as using web browsers. To do that I wanted to remove the
In the MATE desktop environment this is easy because there is a native menu editor. One single mouse click on the respective menu item check box and the menu item no longer appears.
Underneath are two changes. One is the respective
/root/.config/menus/mate-applications.menu file is modified. Another is a copy of
mate-network.directory is created in
/root/.local/share/desktop-directories. The latter file contains the
Xfce is a different beast. For years users have asked for a native menu editor. Instead the developers recommend existing third party editors, such as
I tried using
menulibre and screamed in horror at the underlying mess of files and convoluted
xfce-applications.menu. Undoing the mess took some doing.
I looked harder at the problem and had a classic light bulb moment. Noticing how the MATE menu was modified, in
/root/.local/share/desktop-directories/ I copied
xfce-network.directory. The new file would override the global file.
To my surprise and delight the trick worked.