TM Ruby and Tabs

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

TM Ruby and Tabs

s.ross
For some reason, over time, about half of my Ruby files have 4-space  
indents and the other half want to indent by 2 spaces. I've been  
living with it, but not my source is looking a bit like it had too  
much to drink last night. Questions:

1) How do I tell TM how many spaces to indent?
2) Is there some cool way to invoke the auto indenter across a whole  
file (I know it will get some of the indents a bit wrong, but it's  
easier than going line by line)?

Thanks


______________________________________________________________________
For new threads USE THIS: [hidden email]
(threading gets destroyed and the universe will collapse if you don't)
http://lists.macromates.com/mailman/listinfo/textmate
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: TM Ruby and Tabs

jeanpierre-2
On 1/14/07, s.ross <[hidden email]> wrote:
For some reason, over time, about half of my Ruby files have 4-space
indents and the other half want to indent by 2 spaces. I've been
living with it, but not my source is looking a bit like it had too
much to drink last night. Questions:

1) How do I tell TM how many spaces to indent?

at the base of the document to the left of the symbol menu

2) Is there some cool way to invoke the auto indenter across a whole
file (I know it will get some of the indents a bit wrong, but it's
easier than going line by line)?

at worst, i think you could probably set your spaces to tab value, select all the text then mash option-command-[ to re-indent.
 
there might be alternate and perhaps more optimal ways to do this but that is what i've come across so far.

cheers,
jean-pierre



______________________________________________________________________
For new threads USE THIS: [hidden email]
(threading gets destroyed and the universe will collapse if you don't)
http://lists.macromates.com/mailman/listinfo/textmate
Loading...