$PATH
François Chaplais
francois.chaplais at mines-paristech.fr
Wed Jan 26 18:02:58 EST 2011
from what I understand, the shell command creates a new shell session which not that of the terminal. As a result, you may have to rebuild $path correctly. Here is what I do to put the TeX executables in the shell's path:
------------------------
on checkTeXPATH -- for MacTeX
put $PATH into theShellPATH
if "/usr/local/bin:" is not in theShellPATH then -- for Ghostcript
put "/usr/local/bin:" & $PATH into $PATH
end if
if "/usr/texbin:" is not in theShellPATH then -- for pdftex etc..
put "/usr/texbin:" & $PATH into $PATH
end if
end checkTeXPATH
--------------------------
HTH
François
Le 26 janv. 2011 à 10:09, David Bovill a écrit :
> Yes - but does it return the same $PATH even after you have customised your
> personal user $PATH with entries in .profile or one of the many other files
> that you can customise yourself, or that installers of command line tools
> often cutomise for you (for instance MacPorts).
>
> Even in MC days on Linux, I found that my own personal shell value of $PATH
> was not the same as the MC result that gets returned with $PATH. I doubt
> this is any different on Fedora Core?
>
> For instance on my OSX system: I can use shell commands because my $PATH in
> the default bash shell is:
>
> /opt/local/bin:/opt/local/sbin:/opt/local/bin:/opt/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin
>>
>
> In LiveCode $PATH (and therefore which command line tools are found) is
> simply:
>
> /usr/bin:/bin:/usr/sbin:/sbin:/opt/local/bin
>
> This is because my .profile settings are:
>
>> # MacPorts Installer addition on 2009-05-28_at_01:12:13: adding an
>> appropriate PATH variable for use with MacPorts.
>> export PATH=/opt/local/bin:/opt/local/sbin:$PATH
>> # Finished adapting your PATH environment variable for use with MacPorts.
>>
>>
>> # MacPorts Installer addition on 2009-05-28_at_01:12:13: adding an
>> appropriate MANPATH variable for use with MacPorts.
>> export MANPATH=/opt/local/share/man:$MANPATH
>> # Finished adapting your MANPATH environment variable for use with
>> MacPorts.
>>
>>
>> ##
>> # Your previous /Users/david/.profile file was backed up as
>> /Users/david/.profile.macports-saved_2009-08-28_at_23:30:02
>> ##
>>
>> # MacPorts Installer addition on 2009-08-28_at_23:30:02: adding an
>> appropriate PATH variable for use with MacPorts.
>> export PATH=/opt/local/bin:/opt/local/sbin:$PATH
>> # Finished adapting your PATH environment variable for use with MacPorts.
>>
>
> Somewhere around I have code that would read and write to these files in
> order to keep the shell environments in LiveCode and the terminal in sync -
> and I need to get this right for the tools I'm working on for LiveCode TV
> shared code libraries, as they interface with various command line tools.
> Need to get to the bottom of these issues cross platform.
>
> On 26 January 2011 01:14, Mark Wieder <mwieder at ahsoftware.net> wrote:
>
>>
>>> AFAIK - the way $PATH works (at least on OSX / Linux) is not the same as
>> you
>>> get when you open your terminal... essentially because it is not using
>> your
>>> .profile or equivalent settings when the shell is initiated. I am not
>> sure
>>> where it gets it's initial setting?
>>
>> $PATH returns my path on Fedora Core. So does
>>
>> put shell("$PATH")
>>
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
More information about the use-livecode
mailing list