Sliced Software
This post is not yet over at tumblr! But it will be soon.
April 20
Properly Close Those Tags In TextMate
In TextMate, I always use ctrl shift . to auto-complete html tags. For example, you can type div then hit ctrl shift . and it will generate <div></div> with your cursor in the middle of the start-end tags. It's an incredible time savor. It also handles things like br turning into <br>. But boy do I hate when my tags aren't properly closed. So if you want br and hr to generate <br/> and <hr/> respectively, fire up your bundle editor (Bundles > Bundle Editor > Show Bundle Editor). Go down to HTML and then 'Insert Open/Close Tag'. Near the bottom of the code apply this diff:
Update:- when single_no_arg then "<#{tag}#{xhtml}>"
+ when single_no_arg then "<#{tag}#{xhtml}/>"
To close other single tags like img and input, also apply the diff below.
- when single then "<#{tag} $1#{xhtml}>"
+ when single then "<#{tag} $1#{xhtml}/>"

