How to find a programs name?

All Gurus once were Newbies
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.
Before you post please read how to get help

How to find a programs name?

Postby Class-- on Sat Mar 10, 2012 7:58 pm

Hi Folks,
So I'm a noob at linux and I'm finding the small things difficult at the moment. Simple things like working out how to find the name of a program to use a command on it in the cli.
I found a "way" but it seems like the long way round as it means the program has to be running for me to see its name ie using the command
Code: Select all
 top
So what is the easiest method? My windows background would be to look at the properties of the shortcut and see the file name there but in gnome3 the only thing that happens on a shortcut is the option to open in new window or add shortcut to the side bar thingy.

Thanks for any input

Class--
Linux n00b
Lisa l0ver :D
Class--
Level 1
Level 1
 
Posts: 25
Joined: Fri Jan 06, 2012 1:26 am

Linux Mint is funded by ads and donations.
 

Re: How to find a programs name?

Postby MALsPa on Sat Mar 10, 2012 9:48 pm

Yeah, in KDE or Xfce, I'd just right-click on the app's icon on the panel to find the command that runs the application.

In GNOME 3, you can open Nautilus and go to /usr/share/applications, find the app, right-click > Properties. There you'll find the actual command that runs the application.
User avatar
MALsPa
Level 8
Level 8
 
Posts: 2030
Joined: Mon Nov 19, 2007 10:17 pm
Location: albuquerque

Re: How to find a programs name?

Postby kyphi on Sat Mar 10, 2012 11:21 pm

I suppose that what you really meant to ask was "how to find the path statement to a program".

If you install "alacarte" (sudo apt-get install alacarte) it will present in your main menu as "Main Menu". All your applications will be listed there and will reveal their path.
Qiana Cinnamon 64bit
User avatar
kyphi
Level 6
Level 6
 
Posts: 1191
Joined: Sat Jul 09, 2011 1:14 am
Location: Australia

Re: How to find a programs name?

Postby Class-- on Wed Mar 14, 2012 7:02 pm

MALsPa wrote:Yeah, in KDE or Xfce, I'd just right-click on the app's icon on the panel to find the command that runs the application.

In GNOME 3, you can open Nautilus and go to /usr/share/applications, find the app, right-click > Properties. There you'll find the actual command that runs the application.

Ahh ha now thats exactly what I wanted. So its the "command" I was after and not the "name" of the program.
See I just find that little bit of info quite hard to find especially since everything in Linux seems to be command line based or am I looking at this from the wrong direction?
Anyway thats another lil hurdle jumped in the 100m hurdle race that is my linux learning curve :D

kyphi wrote:I suppose that what you really meant to ask was "how to find the path statement to a program".

If you install "alacarte" (sudo apt-get install alacarte) it will present in your main menu as "Main Menu". All your applications will be listed there and will reveal their path.

Cheers kyphi, I've installed it and I guess thats just another way of doing what MALsPa said.

Thanks for the info folks.

Class--
Linux n00b
Lisa l0ver :D
Class--
Level 1
Level 1
 
Posts: 25
Joined: Fri Jan 06, 2012 1:26 am

Re: How to find a programs name?

Postby Arcturus691 on Wed Mar 14, 2012 7:21 pm

I find that the easiest way is to open a terminal and type the following:
which [program name]

for example:

which chromium-browser

this gives the result:
/usr/bin/chromium-browser

I know the command line in other operating systems is shunned but it is worth knowing some of the basics in the terminal command line.
Arcturus691
Level 1
Level 1
 
Posts: 5
Joined: Wed Mar 14, 2012 4:58 pm

Re: How to find a programs name?

Postby Class-- on Thu Mar 22, 2012 11:45 am

See now that's what I'm talking about. Where do u find out (simply) that chronium is called chromium-browser when using the command line. That's what my initial post is about. Let's just say I wanted to use the "which" command on firefox. That's easy I just follow what your saying and type
Code: Select all
which firefox

Great that worked as long as I remember it always starts with a lowercase letter. Now what if I want to do a "which" command for my BitDefender antivirus program. Following my success with firefox I automatically type in
Code: Select all
which bitDefender
and bam I'm hit with linux askin me confused I'm on about :( so this means I can't do anything "the easy way" as I'm stuck at the first obstacle and it seems a fairly simple one. Its just I have to do what MALsPA said which seems far from the whole "easy" way. Or I could run the program from the shortcut and then run "top" in the terminal and then and only then know what to type ie.
Code: Select all
which bdGUI
so the question is this... Am I the idiot here not seeing something simple? Or is this a gnome 3 thing? OR is this a linux thing?

Cheers for reading folks

Class--
Linux n00b
Lisa l0ver :D
Class--
Level 1
Level 1
 
Posts: 25
Joined: Fri Jan 06, 2012 1:26 am

Re: How to find a programs name?

Postby Habitual on Thu Mar 22, 2012 12:09 pm

which <program>
whereis <program>
locate <program>
ps -e | grep "*part of program name*"

Launcher properties are the easiest method.
What's a landing but a take off in reverse?
User avatar
Habitual
Level 8
Level 8
 
Posts: 2248
Joined: Sun Nov 21, 2010 8:31 pm
Location: LM17Q-Xfce

Re: How to find a programs name?

Postby Class-- on Thu Mar 22, 2012 4:41 pm

Habitual wrote:which <program>
whereis <program>
locate <program>
ps -e | grep "*part of program name*"

Launcher properties are the easiest method.

Hi Habitual,
Sorry but what do you mean by this? I dont quite understand what your trying to tell this n00b :)
But my main point is how can anyone do any of what you have said if they cant find out what to insert in the <program> part because its not easy to find that info out?

Thanks for replys

Class--
Linux n00b
Lisa l0ver :D
Class--
Level 1
Level 1
 
Posts: 25
Joined: Fri Jan 06, 2012 1:26 am

Re: How to find a programs name?

Postby Arcturus691 on Mon Mar 26, 2012 1:02 pm

Class-- wrote:See now that's what I'm talking about. Where do u find out (simply) that chronium is called chromium-browser when using the command line. That's what my initial post is about. Let's just say I wanted to use the "which" command on firefox. That's easy I just follow what your saying and type
Code: Select all
which firefox

Great that worked as long as I remember it always starts with a lowercase letter. Now what if I want to do a "which" command for my BitDefender antivirus program. Following my success with firefox I automatically type in
Code: Select all
which bitDefender
and bam I'm hit with linux askin me confused I'm on about :( so this means I can't do anything "the easy way" as I'm stuck at the first obstacle and it seems a fairly simple one. Its just I have to do what MALsPA said which seems far from the whole "easy" way. Or I could run the program from the shortcut and then run "top" in the terminal and then and only then know what to type ie.
Code: Select all
which bdGUI
so the question is this... Am I the idiot here not seeing something simple? Or is this a gnome 3 thing? OR is this a linux thing?

Cheers for reading folks

Class--


Ok this is where the find command comes into play:

for example: find /usr/bin -iname GEDIT

the above command tells find to search from the "/" root directory, ignore case (-i) name followed by what you are searching for. This gives you the results for gedit. Also you can use wild cards if you only know part of the name:
find /usr/bin -iname chrom*
So that addresses the question about knowing the case.

You may want to learn more about how the linux directory structure is setup, I have taken classes on linux, which made it much easier to navigate linux via command line. I remember correctly most user installed programs are stored in /opt or /usr. With that said IMHO I would like to see more gui tools for those that do want to dig deeper and use the command line.

update: found a tutorial on the terminal (command line): http://community.linuxmint.com/tutorial/view/100
Arcturus691
Level 1
Level 1
 
Posts: 5
Joined: Wed Mar 14, 2012 4:58 pm

Linux Mint is funded by ads and donations.
 

Return to Newbie Questions

Who is online

Users browsing this forum: all41, Bing [Bot], Hecubus, Mute Ant and 31 guests