Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error message: pdflatex not found #19

Open
fbreuer opened this issue Jan 7, 2015 · 12 comments
Open

error message: pdflatex not found #19

fbreuer opened this issue Jan 7, 2015 · 12 comments

Comments

@fbreuer
Copy link

fbreuer commented Jan 7, 2015

When trying to compile a TeX file I get the error message

/bin/sh: pdflatex: command not found

However, pdflatex is installed and on the path. Running pdflatex from a terminal works fine, even from one using /bin/sh instead of /bin/bash as shell.

@rschroll
Copy link
Owner

Sorry -- I must have missed the email for this bug when you reported it. What OS are you using? What is your default shell?

If you're using OSX, this sounds a lot like #5.

@mrtzh
Copy link

mrtzh commented Feb 10, 2015

Same issue for me. I followed the other thread which doesn't do it for me. My tex setup works fine otherwise. I use it every day.

I tried manually specifying a path in the litex config, but that didn't seem to help.

@rschroll
Copy link
Owner

Same questions to you: Which OS? What's your default shell (if
applicable)?

Also, if you could post your modified litexrc file and the resultant
error message, it might give us some clues.

@mrtzh
Copy link

mrtzh commented Feb 10, 2015

Mac OS X 10.10.1
MacTex 2014 (TexLive 2014)
I can run "pdflatex" from any shell (sh, bash, tcsh) and it works.

I added the following in my .literc file in the appropriate place:

 "commands": ["/usr/texbin/pdflatex"]

It results in the same error message as before:

/bin/sh: pdflatex: command not found

@rschroll
Copy link
Owner

The fact that the error message references "pdflatex", and not
"/usr/bin/pdflatex" makes me suspect that the latexrc file is not being
used. First, I'd like to double check that the file is named
".litexrc", not ".literc". I suspect you just mistyped in the bug
report, but I want to be sure. :)

Then, I'd try changing the command to something that definitely doesn't
exist, and see if the error message updates. If it doesn't, then the
setting isn't being applied for some reason. Make sure the .litexrc
file is in the same directory as your tex file, and make sure you're
using the compilation command that corresponds to the one you're
running (Cmd-Enter or Cmd-Shift-Enter, for file and project,
respectively).

@mrtzh
Copy link

mrtzh commented Feb 11, 2015

Yeah, that was a typo, but still I messed up. I think I broke the local .litexrc so that litex skipped straight to the global rc file that still had the old setting in it. In the end what fixed it was simply to specify the absolute path in the rc file:

    "commands": ["/usr/texbin/pdflatex \"%f\""]

Thanks for your quick response.

@arielleon
Copy link

Hi,
I think I got the same problem. May I ask where to find .litexrc file? Thx!

Ariel

@rschroll
Copy link
Owner

rschroll commented Apr 5, 2015

Litex will check two configuration files, first "litexrc" in your XDG
data directory (~/.config/ on most linuxes) and then ".litexrc" in the
current working directory. You can open these files in LightTable with
the "Edit global LaTeX compilation settings" command and the "Edit
local LaTeX compilation settings" command. (If those files don't
exist, they will be created for you with a template for you to edit.)

@arielleon
Copy link

Thank you! Yet surprisingly I still get the same error, after editting both the global and local "litexrc".
I add
"commands": ["/usr/texbin/pdflatex "%f""]
under the line
//"commands": "pdflatex",

Wenjie

@rschroll
Copy link
Owner

rschroll commented Apr 8, 2015

Are you getting any other error messages in the LightTable console? My
first suspicion is that something is messed up in the rc files, and
Litex is ignoring them. You can also try changing the command to an
executable that doesn't exist and check that the error message changes.
If not, that means the rc file is being ignored for some reason.

@arielleon
Copy link

I think they are not ignored.
I change either one file into
"commands": ["/usr/texbin/pdflatex "%f""
without the "]".
In either case, I get error in console:
litex_compiled.js[122]:
Error parsing /Users/wenjieji/Library/Application Support/litexrc:
SyntaxError: Unexpected token }
Ignoring this file.
While before changing, I had no errors in console.

Wenjie

@arielleon
Copy link

I fixed this problem on OS X EI Captian.
On EI Captian, when installing MacTex-2015, it creates a symbolic link to /Library/Tex/texbin, rather than /usr/texbin. So in "litexrc" file, ( I open the global one by using the "Edit global LaTeX compilation settings" command in lighttable) add

"commands": ["/Library/Tex/texbin/pdflatex "%f""]
under the line
//"commands": "pdflatex"

Wenjie

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants