Real world ruby programs to learn from

Hi,

Can you recommend some Ruby projects in which I can have a look to learn
good Ruby practices / idioms and why not contribute to them? I am fed up
with the stupid code examples we find in books.

The Ruby on Rails code is a bit too complex to start with I guess.

Fernando P. wrote:

Hi,

Can you recommend some Ruby projects in which I can have a look to learn
good Ruby practices / idioms and why not contribute to them? I am fed up
with the stupid code examples we find in books.

The Ruby on Rails code is a bit too complex to start with I guess.

I think http://pleac.sf.net is the site you need to visit.

Your link seems very interesting and cool to learn from and can very
very helpful to jump from one language to another.

2008/9/30 Fernando P. [email protected]:

Your link seems very interesting and cool to learn from and can very
very helpful to jump from one language to another.

I had a quick look at
Process Management and Communication and
I must say this is far from correct or ideal. Issues I have spotted
on first check:

readme = IO.popen(“ls”) # does not use block form

$stdout = writeme # must be $stdout.reopen(writeme)

Process.waitpid(pid, 0) # should come after the read loop otherwise
deadlock may occur

Kind regards

robert

Robert K. wrote:

2008/9/30 Fernando P. [email protected]:

Your link seems very interesting and cool to learn from and can very
very helpful to jump from one language to another.

I had a quick look at
Process Management and Communication and
I must say this is far from correct or ideal. Issues I have spotted
on first check:

readme = IO.popen(“ls”) # does not use block form

$stdout = writeme # must be $stdout.reopen(writeme)

Process.waitpid(pid, 0) # should come after the read loop otherwise
deadlock may occur

Kind regards

robert

Robert , pleac is “a work in progress” . Anyone can make contributions
to it . It would be great if you would submit corrections to bugs you
found , if you can spare the time , of course .

Lex

2008/9/30 Lex W. [email protected]:

readme = IO.popen(“ls”) # does not use block form
Robert , pleac is “a work in progress” . Anyone can make contributions
to it . It would be great if you would submit corrections to bugs you
found , if you can spare the time , of course .

I know. But time is lacking ATM. :slight_smile:

robert

Robert , pleac is “a work in progress” . Anyone can make contributions
to it . It would be great if you would submit corrections to bugs you
found , if you can spare the time , of course .

Lex

Argh too bad there are not always good coding practices, that’s a reason
why I avoid looking at refactormycode for instance, there are too many
funky solutions proposed.

Hi –

On Tue, 30 Sep 2008, Lex W. wrote:

readme = IO.popen(“ls”) # does not use block form
Robert , pleac is “a work in progress” . Anyone can make contributions
to it . It would be great if you would submit corrections to bugs you
found , if you can spare the time , of course .

I submitted some suggestions a few years ago, I think involving
switching something so that it used a block, and I was told that that
wouldn’t be good because it wasn’t similar enough to other languages
to compare.

I got the impression that pleac was mostly Perl being written in a
variety of languages, but I haven’t looked at it in a while.

David

-------- Original-Nachricht --------

Datum: Tue, 30 Sep 2008 23:51:18 +0900
Von: Fernando P. [email protected]
An: [email protected]
Betreff: Re: Real world ruby programs to learn from

Posted via http://www.ruby-forum.com/.
Dear Fernando,

I think a good place to look at many solutions to many problems and
sometimes very
insightful comments is the Rubyquiz site:

http://rubyquiz.com/

Best regards,

Axel

On Tue, Sep 30, 2008 at 2:58 PM, Martin DeMello
[email protected] wrote:

On Tue, Sep 30, 2008 at 12:09 PM, Axel E. [email protected] wrote:

I think a good place to look at many solutions to many problems and sometimes very
insightful comments is the Rubyquiz site:

Actually, just this once I would not recommend the rubyquiz site - the
programs there aren’t written with an eye on maintainability.

martin

I agree with martin. There are only a handful of quizes that have
real-world applicability, and of the answers to those, only a small
percentage exhibiting good coding practices (my own included).

If someone hasn’t already mentioned this, look at some of the stdlib
code, and cast your glance over the many projects on rubyforge.

Todd

On Tue, Sep 30, 2008 at 12:09 PM, Axel E. [email protected] wrote:

I think a good place to look at many solutions to many problems and sometimes very
insightful comments is the Rubyquiz site:

Actually, just this once I would not recommend the rubyquiz site - the
programs there aren’t written with an eye on maintainability.

martin

Fernando P. wrote:

Hi,

Can you recommend some Ruby projects in which I can have a look to learn
good Ruby practices / idioms and why not contribute to them? I am fed up
with the stupid code examples we find in books.

The Ruby on Rails code is a bit too complex to start with I guess.

Yes, I too am on the lookout for some good, working projects that i
can look at the source code and understand how small to medium size
projects are structured and coded.
Not samples, tutorials, snippets etc. I am writing my first ruby app
(after writing a lot of small one-file scripts) - please suggest a few
project names.