[TxMt] plugin/ackmate patch to open files in symlinked dirs
Stephen Bannasch
stephen.bannasch at deanbrook.org
Fri Sep 3 02:31:05 UTC 2010
I've patched the ackmate plugin for textmate to fix the problem described in this issue:
Searching inside symlinked folders opens a new window
http://github.com/protocool/AckMate/issues#issue/5
Trevor Squires had been opening a a file like this from the plugin:
[[[NSApplication sharedApplication] delegate] openFiles:[NSArray arrayWithObject:absolute]];
Evidently after passing through Cocoa the original path to the file, which includes a dir symlink, is converted to the
equivalent path without the symlink before textmate proper gets the event. Texmate then opens the file in a new window because
it isn't in the project path anymore.
Here's the change I made:
http://github.com/stepheneb/AckMate/commit/1bc7e4ca698b51b2a0d523ecea277bfb808ab0b9
Which was to call Texmate going through the shell with an NSTask.
I'm wondering if there is a better way -- Trevor thought my hack was a bit ugly ;-)
More information about the textmate
mailing list