From: Xavier Noria Date: 2007-02-09T03:50:17+09:00 Subject: Re: auto indentation in ruby electric mode On Feb 8, 2007, at 6:05 PM, dannyyuan@gmail.com wrote: > Hi, > I'm learning to use Emacs to program Ruby. The ruby-electric-mode > works well except that after I hit ENTER, my cursor will not be > automatically indented. For example, if I type "def foo" and then > ENTER, my cursor will be placed at the first column instead of being > properly indented, say, two spaces to the right of "def". Is there any > way to make the electric mode do auto indentation? Thanks! By default, in Emacs that is accomplished with C-j (newline-and- indent). You may map RET to C-j if that's more natural for you. -- fxn