How commands defined in my shell RC file (e.g. .bashrc) can be made visible to Texmaker?

Consider the following code:

\addplot shell {python -c 'print 0,0'};
\addplot shell {octave -q --eval 'disp([0 0])'};

On my Linux machine, Python is available to all users, but GNU Octave is only added to the path later in my .bashrc. Both plots will work if I compile by hand:

$ pdflatex -shell-escape foo.tex

If I try it within Texmaker, only Python is found.

  • Why don't you add the path for Octave to .bash_profile? – egreg Nov 13 '13 at 18:09
  • @egreg, I thought of it, will try it if no other solution is available. Actually, I'm just lazy to restart my computer. :) – juliohm Nov 13 '13 at 18:14
  • @egreg, see my answer, the correct place to add the path is ~/.profile. – juliohm Nov 14 '13 at 10:14

Texmaker is probably calling Bash as sh, the consequence is that external commands defined in ~/.bashrc aren't visible.

The correct place to set the environment is ~/.profile (not ~/.bash_profile).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.