[Solved] Locate executable for newly installed program?

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
Post Reply
tallyrand
Level 1
Level 1
Posts: 7
Joined: Thu Aug 16, 2018 7:23 am

[Solved] Locate executable for newly installed program?

Post by tallyrand » Wed Sep 12, 2018 7:13 am

Hi,
I'd like to use latex at the command line on mint. I issue the command 'latex' and am told

Command 'latex' not found, but can be installed with:
sudo apt install texlive-latex-base

I issue the suggested command and latex appears to install successfully. However, re-entering 'latex' then just leads to the same response as before. I'm guessing that I somehow have to add the directory where latex has been installed to my search path, but i don't know how to find that directory. Can anyone help?
tally
Last edited by tallyrand on Wed Sep 12, 2018 7:30 am, edited 1 time in total.

User avatar
xenopeek
Level 24
Level 24
Posts: 23193
Joined: Wed Jul 06, 2011 3:58 am
Location: The Netherlands

Re: Locate executable for newly installed program?

Post by xenopeek » Wed Sep 12, 2018 7:16 am

That package installs the binary /usr/bin/latex. If the directory /usr/bin is not in your PATH you have a real issue.

Check what is in your PATH:
echo $PATH
Check that the file /usr/bin/latex exists and is an executable:
file /usr/bin/latex
Image

tallyrand
Level 1
Level 1
Posts: 7
Joined: Thu Aug 16, 2018 7:23 am

Re: Locate executable for newly installed program?

Post by tallyrand » Wed Sep 12, 2018 7:29 am

xenopeek wrote:
Wed Sep 12, 2018 7:16 am
That package installs the binary /usr/bin/latex. If the directory /usr/bin is not in your PATH you have a real issue.

Check what is in your PATH:
echo $PATH
Check that the file /usr/bin/latex exists and is an executable:
file /usr/bin/latex
Thank you. I ran the installation command again then used 'file /usr/bin/latex' to find that /usr/bin/latex is a symbolic link to pdftex and now all seems to be working. I'm not sure why it wasn't after my first installation attempt.

User avatar
BenTrabetere
Level 5
Level 5
Posts: 767
Joined: Sat Jul 19, 2014 12:04 am
Location: Hattiesburg, MS USA

Re: [Solved] Locate executable for newly installed program?

Post by BenTrabetere » Wed Sep 12, 2018 10:23 am

Use the which command to locate commands. It will provide the full path to the executable.

Code: Select all

$ which latex
/usr/bin/latex

Post Reply

Return to “Newbie Questions”