Folding editor for ruby code browsing

K

Kelly Felkins

------=_Part_1978_10853509.1114527986773
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

Question: folding is available in emacs for other languages. Is there a=20
reason its not in ruby-mode?=20

=20

=20
Vim is *awesome* at folding. And *awesome* at everything else I have trie= d=20
so
far. I wish I had spent a day learning vim _years_ ago.
=20
Its a bit like snow-boarding; I put off learning for ages (because I=20
didn't
want to waste a holiday) But I haven't put on skis since I tried it ;)
=20
_Sincere_ thanks for the recommendation!
=20
Andrew Walrond
=20

------=_Part_1978_10853509.1114527986773--
 
A

Andrew Walrond

Question: folding is available in emacs for other languages. Is there a
reason its not in ruby-mode?
Not like this its not (at least not as far as I have managed to find).
This command
:set foldmethod=syntax
does the magic. Now edit a ruby file and it is loaded up fully folded,
with real easy fold manipulation commands (zo - fold close, zo - fold open,
etc.)

You can even save the state of your folds (or several states) and reload
at will.

I am _seriously_ impressed.
 
T

Thomas Kirchner

--liOOAslEiF7prFVr
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

* On Apr 27 0:01 said:
Vim is *awesome* at folding. And *awesome* at everything else I have=20
tried so far. I wish I had spent a day learning vim _years_ ago.

I wish I could un-spend the time I had to use emacs years ago ;) (just=20
kidding, I don't intend to start an editor war!)

If it's possible for a text editor to be life changing, that's vim. Want=
=20
to know the best part? It just keeps getting better as you learn more=20
and more about it. The sad thing is I've had trouble with lots of other=20
programs when I hit escape after entering text. It seems they're not=20
smart enough for vi-syntax. :p

I guess my only (very minor) complaint is that the ruby syntax isn't=20
*quite* perfect yet, but it's darn good.
Its a bit like snow-boarding; I put off learning for ages (because I=20
didn't want to waste a holiday) But I haven't put on skis since I tried= =20
it ;)

Now that's something still on my todo list... I've been a skier for=20
years, and my wife really wants to take up snowboarding. And seeing as=20
it's only April, we've got another good month of snow in line for my=20
area!
_Sincere_ thanks for the recommendation!

No problem. Oh, and in a few days, you may come to like how your wrists=20
feel, too... emacs is painful.
Tom

--liOOAslEiF7prFVr
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)

iD8DBQFCbpur/rVdTqQq7OwRApJ1AJoDbF/cgBa44S9tVOGXdjdvYNNYGgCfTeVR
rzOA1X9gZUEI9x0AV9P8DAg=
=U9Xa
-----END PGP SIGNATURE-----

--liOOAslEiF7prFVr--
 
A

Andrew Walrond

I guess my only (very minor) complaint is that the ruby syntax isn't
*quite* perfect yet, but it's darn good.

I've also found a couple little problems with the syntax parser. Very minor
though. Have you tried emailing the maintainer? Know if he/she is still
active?

Andrew
 
D

Doug Kearns

It probably never will be but it might get close assuming some common
coding conventions are followed...
I've also found a couple little problems with the syntax parser. Very minor
though.

You can send them to me, the (e-mail address removed) list, or enter
them in the bug tracker at http://rubyforge.org/projects/vim-ruby - I'm
not too fussed.
Have you tried emailing the maintainer? Know if he/she is still
active?

It's rumoured that he is... ;-)

Regards,
Doug
 
A

Andrew Walrond

Hi Doug,

You can send them to me, the (e-mail address removed) list, or enter
them in the bug tracker at http://rubyforge.org/projects/vim-ruby - I'm
not too fussed.


It's rumoured that he is... ;-)

;)

This one I found breaks the syntax and folding mechanism:

variable = if something then value1
elsif something then value2
else value3
end

It's not a nice construct, but xemacs and Kate handle it ok, so I guess it
would be nice if vim did too.

I had to replace it with
if something then variable=value1
elsif something then variable=value2
else variable=value3
end

which is obviously handled.

There was another ... can't remember what it was right now though. It'll come
to me...

Andrew
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,774
Messages
2,569,598
Members
45,151
Latest member
JaclynMarl
Top