Hello,
I'm having trouble syncing LaTeX in the direction TextMate --> Skim. Specifically, I'm (still) using this script: http://ebundles.googlecode.com/svn/trunk/Bundles/Latex.tmbundle/Commands/Fin...
and the following lines don't work for me:
if [[ "$V" == Skim ]]; then SCRIPT="$(find_app Skim.app)/Contents/Resources/displayline" if [[ -x "$SCRIPT" ]]; then "$SCRIPT" &>/dev/console "$TM_LINE_NUMBER" "$PDF" "$TM_FILEPATH" else echo "Unable to locate $V." fi fi
I found a workaround which is to comment out and replace as follows
if [[ "$V" == Skim ]]; then SCRIPT="$(find_app Skim.app)/Contents/Resources/displayline" # if [[ -x "$SCRIPT" ]]; then /Volumes/Home/Applications/Skim.app/Contents/SharedSupport/displayline &>/dev/console "$TM_LINE_NUMBER" "$PDF" "$TM_FILEPATH" # else # echo "Unable to locate $V." # fi fi
That said, I don't understand why I can't get it working in its original form, because find_app appears to work and displayline appears executable:
FZs-MacBook:bin fz$ pwd /Volumes/Home/Applications/TextMate.app/Contents/SharedSupport/Support/bin FZs-MacBook:bin fz$ ./find_app Skim.app /Volumes/Home/Applications/Skim.appFZs-MacBook:bin fz$ ls -l /Volumes/Home/Applications/Skim.app/Contents/SharedSupport/displayline -rwxr-xr-x@ 1 fz staff 1735 Mar 12 2012 /Volumes/Home/Applications/Skim.app/Contents/SharedSupport/displayline FZs-MacBook:bin fz$
Can anyone suggest a better fix than my workaround?
Thanks in advance,
Francois
Hi Francois,
So I've just played around with the default LaTeX bundle PDF Sync stuff, and it all seems to work nicely. The code you show below seems to be very old (and the command as it appears in the default bundle is quite different to the one you point to here). Is there a reason you're using this (older) version of the bundle?
Cheers,
David.
On 21 September 2012 10:22, FZiegler fz.2009@klacto.net wrote:
Hello,
I'm having trouble syncing LaTeX in the direction TextMate --> Skim. Specifically, I'm (still) using this script: http://ebundles.googlecode.com/svn/trunk/Bundles/Latex.tmbundle/Commands/Fin...
and the following lines don't work for me:
if [[ "$V" == Skim ]]; then SCRIPT="$(find_app Skim.app)/Contents/Resources/displayline" if [[ -x "$SCRIPT" ]]; then "$SCRIPT" &>/dev/console "$TM_LINE_NUMBER" "$PDF" "$TM_FILEPATH" else echo "Unable to locate $V." fi fi
I found a workaround which is to comment out and replace as follows
if [[ "$V" == Skim ]]; then SCRIPT="$(find_app Skim.app)/Contents/Resources/displayline" # if [[ -x "$SCRIPT" ]]; then /Volumes/Home/Applications/Skim.app/Contents/SharedSupport/displayline &>/dev/console "$TM_LINE_NUMBER" "$PDF" "$TM_FILEPATH" # else # echo "Unable to locate $V." # fi fi
That said, I don't understand why I can't get it working in its original form, because find_app appears to work and displayline appears executable:
FZs-MacBook:bin fz$ pwd /Volumes/Home/Applications/TextMate.app/Contents/SharedSupport/Support/bin FZs-MacBook:bin fz$ ./find_app Skim.app /Volumes/Home/Applications/Skim.appFZs-MacBook:bin fz$ ls -l /Volumes/Home/Applications/Skim.app/Contents/SharedSupport/displayline -rwxr-xr-x@ 1 fz staff 1735 Mar 12 2012 /Volumes/Home/Applications/Skim.app/Contents/SharedSupport/displayline FZs-MacBook:bin fz$
Can anyone suggest a better fix than my workaround?
Thanks in advance,
Francois
textmate mailing list textmate@lists.macromates.com http://lists.macromates.com/listinfo/textmate
On Sep 20, 2012, at 9:45 PM, David Howden wrote:
Hi Francois,
So I've just played around with the default LaTeX bundle PDF Sync stuff, and it all seems to work nicely. The code you show below seems to be very old (and the command as it appears in the default bundle is quite different to the one you point to here). Is there a reason you're using this (older) version of the bundle?
Well, you could certainly chalk it up to laziness on my part. The fact is, I once customized (other parts of what was then) the stock bundle, so now I'm used to it and have a feeling that I know what it does. Soo... I never felt the need to switch and reimplement my customizations in the new bundle, which also felt slower when I once tried it. Nor was I ever clear what to choose between
https://github.com/textmate/latex.tmbundle https://github.com/paulhagstrom/LaTeX.tmbundle
and other forks I may be missing. More seriously, I tried the above two this afternoon for syncing -- perhaps not hard enough, because unlike you, I wasn't successful in the TextMate --> Skim direction. Maybe it's a quirk of my setup? (I'm using 1.5.11 (1635) on OS X 10.6.8.) In any event, my "old" bundle is the only one I found a workaround in, perhaps because I understand its languages (shell and python) better than e.g. ruby.
Thanks anyway, and I'll take your word as encouragement to give a newer bundle another chance if/when I get around to it.
Francois
Cheers,
David.
On 21 September 2012 10:22, FZiegler fz.2009@klacto.net wrote:
Hello,
I'm having trouble syncing LaTeX in the direction TextMate --> Skim. Specifically, I'm (still) using this script: http://ebundles.googlecode.com/svn/trunk/Bundles/Latex.tmbundle/Commands/Fin...
and the following lines don't work for me:
if [[ "$V" == Skim ]]; then SCRIPT="$(find_app Skim.app)/Contents/Resources/displayline" if [[ -x "$SCRIPT" ]]; then "$SCRIPT" &>/dev/console "$TM_LINE_NUMBER" "$PDF" "$TM_FILEPATH" else echo "Unable to locate $V." fi fi
I found a workaround which is to comment out and replace as follows
if [[ "$V" == Skim ]]; then SCRIPT="$(find_app Skim.app)/Contents/Resources/displayline" # if [[ -x "$SCRIPT" ]]; then /Volumes/Home/Applications/Skim.app/Contents/SharedSupport/displayline &>/dev/console "$TM_LINE_NUMBER" "$PDF" "$TM_FILEPATH" # else # echo "Unable to locate $V." # fi fi
That said, I don't understand why I can't get it working in its original form, because find_app appears to work and displayline appears executable:
FZs-MacBook:bin fz$ pwd /Volumes/Home/Applications/TextMate.app/Contents/SharedSupport/Support/bin FZs-MacBook:bin fz$ ./find_app Skim.app /Volumes/Home/Applications/Skim.appFZs-MacBook:bin fz$ ls -l /Volumes/Home/Applications/Skim.app/Contents/SharedSupport/displayline -rwxr-xr-x@ 1 fz staff 1735 Mar 12 2012 /Volumes/Home/Applications/Skim.app/Contents/SharedSupport/displayline FZs-MacBook:bin fz$
Can anyone suggest a better fix than my workaround?
Thanks in advance,
Francois
On Sep 21, 2012, at 1:00 AM, FZiegler wrote:
On Sep 20, 2012, at 9:45 PM, David Howden wrote:
The code you show below seems to be very old (and the command as it appears in the default bundle is quite different to the one you point to here).
Well, I see it using find_app just the same here:
https://github.com/textmate/latex.tmbundle/blob/master/Support/bin/texMate.p...
which I think gave me the same fleeting error message, a kind of tooltip to the effect that Skim was not being found. (Why, is what I have no idea of.) As to the Hagstrom bundle, it seems to have much the same workaround as I used, only hard-coding Skim to a different path than I do:
https://github.com/paulhagstrom/LaTeX.tmbundle/blob/master/Commands/Jump%20t...
Francois
Thanks anyway, and I'll take your word as encouragement to give a newer bundle another chance if/when I get around to it.
Francois
More seriously, I tried the above two this afternoon for syncing -- perhaps not hard enough, because unlike you, I wasn't successful in the TextMate --> Skim direction. Maybe it's a quirk of my setup? (I'm using 1.5.11 (1635) on OS X 10.6.8.) In any event, my "old" bundle is the only one I found a workaround in, perhaps because I understand its languages (shell and python) better than e.g. ruby.
Ah. So I'm on 10.8.2 and running the latest TM2 build (from source) so I'm in no position to help at all! I'm pretty sure that the official latex bundle on github has some "TM2 specific" changes applied to it, so you are probably best sticking to the one you have.
I would recommend trying out TM2 though. I used it for my thesis and didn't have any problems with the official latex support (at least, not after I applied some patches in the first few days of use!). You will have to get a 10.6 build (the more recent builds have been 10.7+ only).
David.
On 21/09/2012, at 02.22, FZiegler wrote:
[…] the following lines don't work for me:
SCRIPT="$(find_app Skim.app)/Contents/Resources/displayline"
[…] workaround […]
/Volumes/Home/Applications/Skim.app/Contents/SharedSupport/displayline &>/dev/console "$TM_LINE_NUMBER" "$PDF" "$TM_FILEPATH"
[…] Can anyone suggest a better fix than my workaround?
How about simply changing the SCRIPT to:
SCRIPT="$(find_app Skim.app)/Contents/SharedSupport/displayline"
Skim moved their script from Resources to SharedSupport and this is why your version broke.
If you do want to try the “latest” (1.x) bundle then a fork exists: https://github.com/textmate/latex.tmbundle/tree/textmate-1.x
On Sep 21, 2012, at 3:51 AM, Allan Odgaard wrote:
On 21/09/2012, at 02.22, FZiegler wrote:
[…] the following lines don't work for me:
SCRIPT="$(find_app Skim.app)/Contents/Resources/displayline"
[…] workaround […]
/Volumes/Home/Applications/Skim.app/Contents/SharedSupport/displayline &>/dev/console "$TM_LINE_NUMBER" "$PDF" "$TM_FILEPATH"
[…] Can anyone suggest a better fix than my workaround?
How about simply changing the SCRIPT to:
SCRIPT="$(find_app Skim.app)/Contents/SharedSupport/displayline"
Skim moved their script from Resources to SharedSupport and this is why your version broke.
Of course! If only I had been *reading* what I wrote :-)
Thanks Allan, for taking the scales off my eyes. Works perfectly.
If you do want to try the “latest” (1.x) bundle then a fork exists: https://github.com/textmate/latex.tmbundle/tree/textmate-1.x
Will try this too, when I get a chance. Thanks again,
Francois