Hi, I made two small changes related to the Reformat Comment command in the Source bundle. The first is to have the command respect the wrap column set in TextMate's interface. The second is a fix to the rubywrap.rb script; it previously did not handle empty comment lines correctly. For example, if you were to run
// lorem ... // // lorem ...
through rubywrap, it will add an extra space at the end of the empty line in the middle. Within the script a regular expression is used to identify comment lines, and this regexp would incorrectly match the newline at the end of the empty line; I changed it so that it only matches trailing spaces. A diff of the changes is attached.
I haven't noticed either of these changes causing problems that didn't exist before; maybe they could be rolled in to the Source bundle?
-Daniel Grady
On 3 Aug 2010, at 01:28, Daniel Grady wrote:
[...] I haven't noticed either of these changes causing problems that didn't exist before; maybe they could be rolled in to the Source bundle?
That would be nice, thanks for the work.
Generally the best way to contribute patches is by forking the bundle from http://github.com/textmate/ and then send a pull request.