In TM2, embedded ruby lines are sometimes being outdented as I type. Here's an example:
= form_for(@consumer_enrollment, url: [@workflow], method: :put, html: { class: 'uniform' }) do |f| = f.fields_for(:consumer_prior_authorizations) do |prior_auth_form|
When typing the second line, hitting backspace at any point or typing the first colon causes the line to outdent to the level of the first line. I can't see any change in the scope, and it doesn't do this in TM1, so I don't know what the issue is. Any ideas?
In a personal bundle, create a new 'Settings' in the bundle editor. Add
{ disableIndentCorrections = '1'; }
to the settings and save it. Set the scope selector if you would like it to only apply to a certain scope, or leave it blank to allow it to affect all scopes. I personally turn off the autoIndent since it's wrong much more often that it is correct for Ruby and CoffeeScript, and it's very persistent. I'm sure once the grammars are rewritten it will work more correctly.
Awesome, thanks!
Brandon Fryslie-2 wrote:
In a personal bundle, create a new 'Settings' in the bundle editor. Add
{ disableIndentCorrections = '1'; }
to the settings and save it. Set the scope selector if you would like it to only apply to a certain scope, or leave it blank to allow it to affect all scopes. I personally turn off the autoIndent since it's wrong much more often that it is correct for Ruby and CoffeeScript, and it's very persistent. I'm sure once the grammars are rewritten it will work more correctly.
-- Brandon Fryslie http://www.MateWiki.com - A TextMate 2 Wiki
On Tuesday, February 28, 2012 at 12:51 PM, mwean wrote:
In TM2, embedded ruby lines are sometimes being outdented as I type. Here's an example:
= form_for(@consumer_enrollment, url: [@workflow], method: :put, html: { class: 'uniform' }) do |f| = f.fields_for(:consumer_prior_authorizations) do |prior_auth_form|
When typing the second line, hitting backspace at any point or typing the first colon causes the line to outdent to the level of the first line. I can't see any change in the scope, and it doesn't do this in TM1, so I don't know what the issue is. Any ideas? -- View this message in context: http://old.nabble.com/haml-embedded-ruby-outdenting-tp33409296p33409296.html Sent from the textmate users mailing list archive at Nabble.com (http://Nabble.com).
textmate mailing list textmate@lists.macromates.com (mailto:textmate@lists.macromates.com) http://lists.macromates.com/listinfo/textmate
textmate mailing list textmate@lists.macromates.com http://lists.macromates.com/listinfo/textmate
This is very helpful instruction. I am a bit confused about the process in creating the new item in the TM2 bundle Editor which from my view does not support "create" anything - only edit.
What am I missing?
Thanks,
Ed.
On Feb 28, 2012, at 12:55 PM, Brandon Fryslie wrote:
In a personal bundle, create a new 'Settings' in the bundle editor. Add
{ disableIndentCorrections = '1'; }
to the settings and save it. Set the scope selector if you would like it to only apply to a certain scope, or leave it blank to allow it to affect all scopes. I personally turn off the autoIndent since it's wrong much more often that it is correct for Ruby and CoffeeScript, and it's very persistent. I'm sure once the grammars are rewritten it will work more correctly.
I just found what I was looking for in the Bundle Editor: ⌘N
Oh, and:
{ disableIndentCorrections = :true; }
works as well.
Thanks,
Ed. On Feb 29, 2012, at 7:45 AM, Edwin Moss wrote:
This is very helpful instruction. I am a bit confused about the process in creating the new item in the TM2 bundle Editor which from my view does not support "create" anything - only edit.
What am I missing?
Thanks,
Ed.
On Feb 28, 2012, at 12:55 PM, Brandon Fryslie wrote:
In a personal bundle, create a new 'Settings' in the bundle editor. Add
{ disableIndentCorrections = '1'; }
to the settings and save it. Set the scope selector if you would like it to only apply to a certain scope, or leave it blank to allow it to affect all scopes. I personally turn off the autoIndent since it's wrong much more often that it is correct for Ruby and CoffeeScript, and it's very persistent. I'm sure once the grammars are rewritten it will work more correctly.
This seems to be an issue with every language I have tried. The comments wrap oddly - or maybe by design - I find it odd when they near the soft-wrap boundary. Let me know if you need more of my settings
Thanks,
Ed
On Mar 2, 2012, at 9:24 AM, Edwin Moss wrote:
This seems to be an issue with every language I have tried. The comments wrap oddly - or maybe by design - I find it odd when they near the soft-wrap boundary. Let me know if you need more of my settings
I reported this earlier to https://github.com/textmate/source.tmbundle/issues/6 (which was the wrong place to report it, but you might find the comments helpful).
On 02/03/2012, at 21.24, Edwin Moss wrote:
This seems to be an issue with every language I have tried. The comments wrap oddly - or maybe by design - I find it odd when they near the soft-wrap boundary.
While one could perhaps ignore the indent settings when there are say, less than 10 columns left, the indented soft wrap works as designed.
On 29/02/2012, at 02.51, mwean wrote:
In TM2, embedded ruby lines are sometimes being outdented as I type. Here's an example: […] Any ideas?
The FAQ talks about indenting: http://wiki.macromates.com/FAQ/TextMate2
You will need to update the rules to work with the embedding (if possible) or disable auto-indent to get 1.x behavior.