Steve, you're a gentleman and a scholar! Thank you.
On 2010-06-17 16:12, Daedal wrote:The first thing I'd recommend is to turn on soft tabs (bottom of the window, in the tab size selector). This will insert spaces instead of tabs, so there won't be anything to convert when it's time to save.
I was wondering if there was maybe a hack or plugin that will allow me to do
this? I'm required to convert all tabs to spaces before committing any code,
and having to do it manually (text->convert->tabs to spaces) on every file
can get pretty frustrating.
If you still want to automatically run the tabs-to-spaces conversion, record it as a macro. Start recording, do tabs-to-spaces, save the file, and stop recording. Then save the macro, go into the bundle editor, and set its activation to "Key Equivalent" and set the key to ⌘-S. Now hitting ⌘-S will convert tabs before saving the file. (It's not a perfect solution though; the File->Save menu item will still have its regular behavior.)
--
Steve King
Sr. Software Engineer
Arbor Networks
+1 734 821 1461
www.arbornetworks.com <http://www.arbornetworks.com/>
_______________________________________________
textmate mailing list
textmate@lists.macromates.com
http://lists.macromates.com/listinfo/textmate