[SVN] Re: r10724 (Latex)
Alex Ross
tm-alex at rosiba.com
Mon Oct 27 14:15:57 UTC 2008
On Oct 27, 2008, at 1:57 PM, Jeroen van der Ham wrote:
> Alexander John Ross wrote:
>> • call TextMate.require_cmd on “kpsewhich”. This is because LaTeX
>> uses a python script as the first arg to Executor, and Executor
>> only checks that it can find that first executable on the PATH.
>> *This* should help users who don't have PATH set.
>>
>> Changed:
>> U trunk/Bundles/Latex.tmbundle/Commands/LaTeX and view.plist
>>
>
> While I do like the change, it doesn't work quite right:
> The first time I started typeset and view, it gave me the error about
> the PATH not being set. I let it fix it, and relaunched TM. Then it
> works. The problem begins when I quit TextMate and launch it again,
> then
> I'm again confronted with the same error. Fixing it and relaunching
> works, but only until I quit TM again.
> I've done this a couple of times now, which has resulted in three PATH
> definitions in the TM preferences.
>
> I'm currently also looking into improving TexMate itself, and I've
> noticed that with this wrapper, TexMate no longer has a proper
> environment. This means that for example it can't just run "find_app"
> (from TM Support). Is there any way to fix that?
Jeroen,
There is a bug in TextMate that is causing the issue you are having.
If you have a PATH var in the preferences, it is *appended* to the
environment instead of replacing the PATH var that already exists.
Then, it is random as to which PATH variable ends up being visible to
the command. You can fix this issue by updating to Bleeding Edge
TextMate with an “option+click” on the “Check for updates” button in
TextMate's preferences.
If you want to access scripts in Support, you can just use
$TM_SUPPORT_PATH to get the path to the support folder. So, the path
to find_app is: "$TM_SUPPORT_PATH/bin/find_app". It is good to avoid
polluting PATH with internal TextMate stuff, to avoid weird behavior
from user programs that might use programs / libraries with the same
names.
—Alex
More information about the textmate-dev
mailing list