I never realized how much easier it makes it to have the relevant
filename extensions like .exe in Windows. :)
Do the package managers use some sort of convention as to where various
kinds of files get installed on Linux systems? I notice there seem to be
a lot of conf files in /etc. Am I on to something here?
in a terminal, type:
which firefox
and it will return the location of _which_ executable the system finds
first in the path..
probably /usr/bin/firefox
--
DenverD (Linux Counter 282315) via Thunderbird 3.0.1-1.1, KDE 3.5.7,
openSUSE Linux 10.3, 2.6.22.19-0.4-default #1 SMP i686 athlon
> Xylene wrote:
>> I'm trying to figure out where the executable of Firefox wound up. This
>> is Ubuntu Jaunty and Firefox 3.0.8 was installed via the Synaptic
>> Manager.
>>
>> I never realized how much easier it makes it to have the relevant
>> filename extensions like .exe in Windows. :)
>>
>> Do the package managers use some sort of convention as to where various
>> kinds of files get installed on Linux systems? I notice there seem to
>> be a lot of conf files in /etc. Am I on to something here?
>
> in a terminal, type:
>
> which firefox
>
> and it will return the location of _which_ executable the system finds
> first in the path..
>
> probably /usr/bin/firefox
Thanks, that's some good info. I'm relatively new to Linux if you
couldn't tell.
i could tell, because you still think having an OS that you have to
TELL it what kind of file it is dealing with (.exe, .jpg, .doc, .pdf,
etc etc etc) is a good thing!
don't worry, stick around long enough and you will eventually come
around to the idea it is better to have an OS smart enough to figure
it out (and save all that typing of ".xxx")
would it be better if you had to type
which.exe firefox.exe
and it answered: C:\winders\programs\executable_bin\firefox.exe ??
> probably /usr/bin/firefox
Which is an executable Bourne shell script which sets up a few configurational
environmental variables and tries to find the real firefox binary, which
at the present time, is to be found at
/usr/lib/firefox-3.0.14/firefox
>would it be better if you had to type
>
>which.exe firefox.exe
Actually, typing a program's ".exe" extension is optional. Windoze is
bad enough w/o making it seem even worse.
however, since i wasn't trying to launch firefox, but rather use the
program which to fine it....if which were looking for firefox and only
firefox.exe existed, then you would have no return unless you typed
firefox.exe or firefox*
see?
> I'm trying to figure out where the executable of Firefox wound up.
> This is Ubuntu Jaunty and Firefox 3.0.8 was installed via the Synaptic
> Manager.
In synaptic you can use "Properties"→"Installed Files" to see the files
of an installed package.
> Do the package managers use some sort of convention as to where various
> kinds of files get installed on Linux systems?
The "The Filesystem Hierarchy Standard". "man hier" has a short version,
the full version is in /usr/share/doc/ubuntu-policy/fhs/ (after
installing the package ubuntu-policy) and at <http://www.pathname.com/fhs/>
Florian
--
<http://www.florian-diesch.de/software/pdfrecycle/>
> Chief Thracian wrote:
> > On Sat, 12 Sep 2009 10:36:57 +0200, DenverD <spam...@SOMEwhere.dk>
> > wrote:
> >
> >> would it be better if you had to type
> >>
> >> which.exe firefox.exe
> >
> > Actually, typing a program's ".exe" extension is optional. Windoze is
> > bad enough w/o making it seem even worse.
>
>
> however, since i wasn't trying to launch firefox, but rather use the
> program which to fine it....if which were looking for firefox and only
> firefox.exe existed, then you would have no return unless you typed
> firefox.exe or firefox*
>
> see?
Actually 'which' requires one to know the exact name of an executable. See
these examples:
[gene@era4 ~]$ which fire
which: no fire in
(/bin:/usr/bin:/usr/local/bin:/usr/games:/usr/lib/qt4/bin:/usr/bin:/opt/kde3/bin:/home/gene/bin)
[gene@era4 ~]$ which fire*
which: no firewall in
(/bin:/usr/bin:/usr/local/bin:/usr/games:/usr/lib/qt4/bin:/usr/bin:/opt/kde3/bin:/home/gene/bin)
[gene@era4 ~]$ which firefox
/usr/bin/firefox
This is why I prefer 'locate' with 'grep' or 'egrep' most of the time when
searching for an executable (or any file):
[gene@era4 ~]$ locate -i fire|grep "bin/"|grep -v "games/"|grep -v "home/"
/usr/bin/firefox
/usr/bin/mozilla-firefox
/usr/sbin/drakfirewall
Of course one must have 'locate' and 'updatedb' installed. Then have a 'cron'
job run 'updatedb' regularly for 'locate' to work. Fortunately most GNU/Linux
distributions install those by default with a cron job set.
--
Gene
i use locate (and grep) also...was amazing/dismayed when in 10.x(?)
they took locate out of the default install..
but, locate won't point to _the_ first firefox 'which' is in the
path...which was what i was trying to with my first post in this thread...