Bill -
I never thought about empty lines in a file - I usually just have a laundry list, or break stuff out into smaller project files. My code intentionally removes whitespace, to prevent the occasional empty line at te bottom of the listfrom growing. Maybe we need to look at creating some kind of plist to cover this?
Mike
It was bothering me that the cleanup command in GTD2 wasn't
preserving whitespace before projects. I.e. this...
* Foo
- bar
* Baz
- bob
- fred
Would be turned into:
* Foo
- bar
* Baz
- bob
- fred
This "fixes" it in a way that'll likely be laughed at. Point and
laugh away, it works for me... :-)
b.bum
Index: GTD2.tmbundle/Commands/Cleanup.tmCommand
===================================================================
--- GTD2.tmbundle/Commands/Cleanup.tmCommand (revision 5658)
+++ GTD2.tmbundle/Commands/Cleanup.tmCommand (working copy)
@@ -17,7 +17,11 @@
if (myTest.pre_match != "+" and myTest.pre_match.length > 0)
puts line
else
- myDone = myDone + line
+ if (line != "\n")
+ myDone = myDone + line
+ else
+ puts "\n"
+ end
end
end
puts myDone</string>
______________________________________________________________________
For new threads USE THIS: textmate@lists.macromates.com
(threading gets destroyed and the universe will collapse if you don't)
http://lists.macromates.com/mailman/listinfo/textmate