[SVN] r6330 (Subversion)
Chris Thomas
chris at cjack.com
Mon Dec 11 19:29:52 UTC 2006
Yes, yes, sorry, I read Haris's note the other day and was suitably
chastened. It hadn't occurred to me that Ruby wouldn't canonicalize
require paths, although I realize it's a Really Hard Problem when
considering all the edge cases and other platforms.
It would be nice someday to be able to write something like 'require
"textmate/progress", though. Would need to move the lib/support ruby
files into a 'textmate' folder and modify RUBYLIB. I wonder if this
can be accomplished without modifying the TM app binary.
Chris
On Dec 11, 2006, at 5:46 PM, James Edward Gray II wrote:
> IMPORTANT NOTE TO BUNDLE DEVELOPERS: Please, refrain from any
> $LOAD_PATH ($:) modifications in bundle support files. I realize
> it is a more elegant way to write requires, but it creates bugs in a
> load system such as we use for the bundles. The problem is that
> support libraries often load other libraries and $LOAD_PATH hacking
> makes the relative paths look like new files, so Ruby loads the
> library more than once. This often triggers redefinition warnings.
> When those warnings end up in the output, as they did with Diff
> commands before this fix, you break the document format. Stick to
> absolute path requires and we won't have this problem anymore.
> Thank you.
>
> Changed:
> U trunk/Bundles/Subversion.tmbundle/Support/svn_commit.rb
> U trunk/Bundles/Subversion.tmbundle/Support/svn_diff.rb
> U trunk/Support/lib/progress.rb
More information about the textmate-dev
mailing list