Originally Posted by
Apolyonn
...
Does anyone know what the command is for this in a terminal?
...
Here's something, not limited to Lubuntu, that gives you both the descriptive name of a program as well as the command to invoke that program in a terminal as Name and Command pairs:
Code:
sed -nrs '/^\[Desktop Entry\]/d;/^(\[|Name=|Exec=)/p;${g;p}' /usr/share/applications/*.desktop > ~/Desktop/a1.txt
This code creates a file called a1.txt on your desktop and it looks like this, in part:
Code:
...
Name=Shutdown
Exec=lubuntu-logout
Name=ScreenLock
Exec=xscreensaver-command -lock
Name=Lubuntu Software Center
Exec=lubuntu-software-center
Name=Customize Look and Feel <<<<<<<<<<<<<<<<<<
Exec=lxappearance
Name=Terminal emulator
Exec=/usr/bin/x-terminal-emulator
Name=Web Browser
Exec=/usr/bin/x-www-browser %u
Name=Keyboard and Mouse
Exec=lxinput
Name=Lxkeymap
Exec=lxkeymap
...
By its nature, it's limited to programs with .desktop files located in /usr/share/applications only. I can't explain the order in which the names and command pairs appear and so the name or command pair may not appear in strict alphabetical order. (The code above is slightly modified from that here.)
Bookmarks