[SVN] PATCH RubyMate relative paths
Ian Levesque
ian at ianlevesque.org
Sun Jul 20 22:59:25 UTC 2008
Hi,
I recently encountered an issue regarding relative paths with RubyMate
and Test::Unit. I have a folder hierarchy like this:
Project/
test/
test_something.rb
test_something_else.rb
...
src/
...
Each of my test_something.rb files starts with a shebang like this:
#!/usr/bin/ruby -I../src
..so that it can find the source files.
This leads to backtraces in RubyMate output that have files with
relative pathnames. Clicking on the links for these files incorrectly
opens a new empty file instead of finding the correct file with the
relative path. It turns out this is already taken care of in
RubyMate's "catch_exception.rb" but NOT in "run_script.rb".
The attached patch fixes the issue by resolving the path using
"Pathname.realpath" in run_script.rb like catch_exception.rb already
does.
I would really like to see this patch (or similar) end up in the
mainstream bundle sources, so if it is unusable as-is please let me
know!
Thanks,
-Ian Levesque
-------------- next part --------------
A non-text attachment was scrubbed...
Name: run_script.diff
Type: application/octet-stream
Size: 1437 bytes
Desc: not available
URL: <http://lists.macromates.com/textmate-dev/attachments/20080720/d5b2633e/attachment.diff>
-------------- next part --------------
More information about the textmate-dev
mailing list