Emacs Ruby-Mode

Was something changed recently in emacs ruby mode in the way it parses lines
that are ended early? For instance if I have a multi line conditional with an
&& and I try to break the line after the && and tab so that the next part of the
conditional starts slightly indented, it now leeps to the same tabstop as the
&&, completely defeating the purpose. The same logic seems to apply to comma’s
on argument lists and in arrays.

For some reason I remember it tabbing better before, but perhaps I am mistaken.
Is this intentional, something that hasn’t been fixed yet, or just an
idiosyncracity of my coding style?

Charles Comstock

I agree that this is annoying. I use \ to let the line continue, that
gives a nicer look, but it seems quite superfluent to me.

a = b +
c

becomes

a = b +
c

I also would want to have this behaviour changed.

Greetings,

Brian

···

On Sun, 23 May 2004 06:13:28 -0500, Charles Comstock wrote:

that are ended early? For instance if I have a multi line conditional with an
&& and I try to break the line after the && and tab so that the next part of the
conditional starts slightly indented, it now leeps to the same tabstop as the
&&, completely defeating the purpose. The same logic seems to apply to comma’s
on argument lists and in arrays.

Hi,

···

In message “Emacs Ruby-Mode” on 04/05/23, Charles Comstock cc1@cec.wustl.edu writes:

Was something changed recently in emacs ruby mode in the way it parses lines
that are ended early? For instance if I have a multi line conditional with an
&& and I try to break the line after the && and tab so that the next part of the
conditional starts slightly indented, it now leeps to the same tabstop as the
&&, completely defeating the purpose. The same logic seems to apply to comma’s
on argument lists and in arrays.

Tell me the version of ruby-mode.el you were using.

						matz.

Hi,

At Mon, 24 May 2004 09:43:46 +0900,
Brian Schroeder wrote in [ruby-talk:101154]:

that are ended early? For instance if I have a multi line conditional with an
&& and I try to break the line after the && and tab so that the next part of the
conditional starts slightly indented, it now leeps to the same tabstop as the
&&, completely defeating the purpose. The same logic seems to apply to comma’s
on argument lists and in arrays.

I agree that this is annoying. I use \ to let the line continue, that
gives a nicer look, but it seems quite superfluent to me.

a = b +
c

With ruby-mode.el 1.81:

if a &&
b
end

a = b +
c

···


Nobu Nakada

Speaking of editor mode and syntax highlighting, any joe users here? The
3.0 release doesn’t include a Ruby syntax file. I’ve tried to create one
but currently it’s very very simplistic (actually, most of the syntax
files are pretty simplistic, e.g. the Perl one doesn’t handle << or qq()
or regexes). Anyone has a better Ruby syntax file?

···


dave

The stable snapshot has ruby-mode
$Date: 2004/01/06 14:00:54 $
(defconst ruby-mode-revision “$Revision: 1.74.2.1 $”)

I’ll try to dig 1.81 out of CVS, but is there a particular reason the version in
the stable snapshot is outdated?

Charlie

···

On Mon, 24 May 2004 nobu.nokada@softhome.net wrote:

Hi,

At Mon, 24 May 2004 09:43:46 +0900,
Brian Schroeder wrote in [ruby-talk:101154]:

that are ended early? For instance if I have a multi line conditional with an
&& and I try to break the line after the && and tab so that the next part of the
conditional starts slightly indented, it now leeps to the same tabstop as the
&&, completely defeating the purpose. The same logic seems to apply to comma’s
on argument lists and in arrays.

I agree that this is annoying. I use \ to let the line continue, that
gives a nicer look, but it seems quite superfluent to me.

a = b +
c

With ruby-mode.el 1.81:

if a &&
b
end

a = b +
c

From stable-snapshot downloaded 20 minutes ago:

;;; $Date: 2004/05/07 08:48:30 $
;;; created at: Fri Feb 4 14:49:13 JST 1994
;;;

(defconst ruby-mode-revision “$Revision: 1.74.2.2 $”)

Is there a reason ruby-mode 1.81 isn’t bundled with it? Or am I
misunderstanding the version numbers.

Charlie

···

On Mon, 24 May 2004 nobu.nokada@softhome.net wrote:

Hi,

At Mon, 24 May 2004 09:43:46 +0900,
Brian Schroeder wrote in [ruby-talk:101154]:

that are ended early? For instance if I have a multi line conditional with an
&& and I try to break the line after the && and tab so that the next part of the
conditional starts slightly indented, it now leeps to the same tabstop as the
&&, completely defeating the purpose. The same logic seems to apply to comma’s
on argument lists and in arrays.

I agree that this is annoying. I use \ to let the line continue, that
gives a nicer look, but it seems quite superfluent to me.

a = b +
c

With ruby-mode.el 1.81:

if a &&
b
end

a = b +
c

David Garamond wrote:

Speaking of editor mode and syntax highlighting, any joe users here? The
3.0 release doesn’t include a Ruby syntax file. I’ve tried to create one
but currently it’s very very simplistic (actually, most of the syntax
files are pretty simplistic, e.g. the Perl one doesn’t handle << or qq()
or regexes). Anyone has a better Ruby syntax file?

I have written a Ruby 2 html colorizer… Maybe it can inspire you?
http://neoneye.dk/syntax.html

···


Simon Strandgaard