I just noticed this change in the Ruby bundle:
"[NEW] The Ruby bundle has a new snippet to generate ERb's <% … %> and <%= … %> tags. Both tags are available via control > (⌃>). Add a tab (⇥) after triggering the snippet if you wish to keep the =. This depreciates the control X (⌃X) and control Z (⌃Z) snippets from the Rails bundle and they will be removed in the future. This feature was designed by the ANSI TextMate Standards Comity"
Which means I'm going to have to retrain my fingers - sooo much easier to type ^z or ^x with on hand, now have to use two... anyway.. Setting a document to "Ruby" or "HTML (Rails)", I tried the new trigger. ^> does give <%= %>, but typing a Tab just inserts a tab. I don't see how to get just a <% %> block? I tried hitting the trigger again (^>) because I see comments about how this should toggle the tags, but all that does is insert another set of <%= %> tags ( <%= <%= %> %> )
What's the magic necessary here?
Thanks, John
On Nov 1, 2006, at 6:48 AM, John Tsombakos wrote:
Setting a document to "Ruby" or "HTML (Rails)", I tried the new trigger. ^> does give <%= %>, but typing a Tab just inserts a tab. I don't see how to get just a <% %> block?
We're still working out the bugs with this approach, so be patient with us. We ditched the tab idea. The system is now:
⌃> = <%= %> ⌃> ⌃> = <% %>
Allan will edit the commit message to reflect this for the next release.
The problem you ran into when testing it was a bug in my implementation. I just committed a fix, so give it another shot.
James Edward Gray II
On 11/1/06, James Edward Gray II james@grayproductions.net wrote:
Allan will edit the commit message to reflect this for the next release.
The problem you ran into when testing it was a bug in my implementation. I just committed a fix, so give it another shot.
Yup, that did it. Just curious what the rational was from going to a nice quick one handed keystroke to one that needs both hands?
jt
On Nov 1, 2006, at 5:25 PM, John Tsombakos wrote:
Just curious what the rational was from going to a nice quick one handed keystroke to one that needs both hands?
We generated a pretty good number of reasons:
* ⌃X and ⌃Z were totally arbitrary * It was wasteful to lose two of the coveted control based shortcuts to these functions * The new trigger is a better mental fit * We only use one trigger now for these related operations * ⌃> pairs nicely with ⌃<
Note that we made other changes to the commands:
* Moved them to the Ruby bundle, since they are a feature of a Ruby standard library and not Rails specifc * Widened their scope to text.html, so you can use them in more places
Hope that explains our thinking a little.
James Edward Gray II
On Nov 1, 2006, at 6:06 PM, James Edward Gray II wrote:
- ⌃X and ⌃Z were totally arbitrary
I agree. i think this is a great change. Comes much more natural. These shortcuts drove me nuts; i probably mixed them up half the time. I guess because of the very similar output and because they are so close together, my brain would just not cooperate :)
sebastian