[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

ruby resources

Jeff Davis

1/27/2005 7:19:00 PM

I've been learning Ruby lately and I think it's a great language.
However, it takes time to figure out where the information and resources
are.

Complete documentation seems to be hard to find. The Programming Ruby
link is nice and very helpful, but it doesn't include any reference
section, and it references page numbers that I can't find (because the
pages online aren't numbered). Some reference documents exist but are
hard to find. Nothing is really searchable.

rdoc is not interactive like perl or python, and requires a path to the
actual ruby file and not just an arbitrary class name (can you rdoc a
built-in class?). It does great html output, however.

It's hard to find good documentation for the modules/classes, built-in
or otherwise.

It's also hard to find modules or classes that aren't built in. I think
I found the 'postgres' module in the RAA, but it isn't exactly an
application, it's more of a library.

I have some idea about what "gems" are but it's confusing how they fit
into the big picture.

Can someone let me know where I can find some of these resources?

It seems as though perl, python, and php have all of these things easily
accessible from the main websites. With ruby, it's very difficult to
even know what website to go to (rubyforge? runy-lang? rubycentral?
ruby-doc? raa?), and there's no clear division of responsibility that I
can see.

I really like the language and community, but perhaps the community
resources put off some of the less determined people from getting into it.

Regards,
Jeff Davis



3 Answers

Dan Fitzpatrick

1/27/2005 8:00:00 PM

0

I've been working with Ruby for about 30 days. These are my links or
particular interest:

http://ruby-la...
http://www.rubycentra...
http://www.postgresql.jp/interfaces/ruby/refe...
http://www.rubygarden.org/ruby...
http://www.erikveen.dds.nl/rubywebdialogs/...
http://wxruby.rubyforge.org/wi...
http://fhwang.net/bl...
http://rrr.jin.gr.j...
http://www.rickbradley.com/chron...
http://www.deveiate.org/code/IO-Re...
http://www.germane-software.com/softw...
http://pub.cozmixng.org/~the-rwiki/rw-cgi.rb?cmd=view;...
http://www.zenspider.com/Languages/Ruby/Qui...
http://www.rubyist.net/~slagell/ruby/ruby...
http://rafb.net/paste/results/nZs...
http://yaml4r.sourceforge.net...
http://www.zytrax.com/tech/...
http://www.brpreiss.com/books/opus8/html...

Dan



Jeff Davis wrote:

> I've been learning Ruby lately and I think it's a great language.
> However, it takes time to figure out where the information and
> resources are.
>
> Complete documentation seems to be hard to find. The Programming Ruby
> link is nice and very helpful, but it doesn't include any reference
> section, and it references page numbers that I can't find (because the
> pages online aren't numbered). Some reference documents exist but are
> hard to find. Nothing is really searchable.
>
> rdoc is not interactive like perl or python, and requires a path to
> the actual ruby file and not just an arbitrary class name (can you
> rdoc a built-in class?). It does great html output, however.
>
> It's hard to find good documentation for the modules/classes, built-in
> or otherwise.
>
> It's also hard to find modules or classes that aren't built in. I
> think I found the 'postgres' module in the RAA, but it isn't exactly
> an application, it's more of a library.
>
> I have some idea about what "gems" are but it's confusing how they fit
> into the big picture.
>
> Can someone let me know where I can find some of these resources?
>
> It seems as though perl, python, and php have all of these things
> easily accessible from the main websites. With ruby, it's very
> difficult to even know what website to go to (rubyforge? runy-lang?
> rubycentral? ruby-doc? raa?), and there's no clear division of
> responsibility that I can see.
>
> I really like the language and community, but perhaps the community
> resources put off some of the less determined people from getting into
> it.
>
> Regards,
> Jeff Davis
>
>


Andrew Johnson

1/27/2005 8:19:00 PM

0

On Fri, 28 Jan 2005 04:18:49 +0900, Jeff Davis <jdavis-list@empires.org> wrote:
[snip]
> rdoc is not interactive like perl or python, and requires a path to the
> actual ruby file and not just an arbitrary class name (can you rdoc a
> built-in class?). It does great html output, however.

Docs on the built-ins can be brought up with ri (part of the included
rdoc stuff) -- though you'll have to make sure you build/install the
docs (make install-doc), or download them from ruby-doc.

ri works like this from the command-line


$ ri Enumerable
------------------------------------------------------ Class: Enumerable
The +Enumerable+ mixin provides collection classes with several
traversal and searching methods, and with the ability to sort. The
class must provide a method +each+, which yields successive members
of the collection. If +Enumerable#max+, +#min+, or +#sort+ is used,
the objects in the collection must also implement a meaningful
+<=>+ operator, as these methods rely on an ordering between
members of the collection.

------------------------------------------------------------------------


Instance methods:
-----------------
all?, any?, collect, detect, each_with_index, entries, find,
find_all, grep, include?, inject, map, max, member?, min,
partition, reject, select, sort, sort_by, to_a, to_set, zip


Want to know what the #partition method does?


$ ri Enumerable.partition
--------------------------------------------------- Enumerable#partition
enum.partition {| obj | block } => [ true_array, false_array ]
------------------------------------------------------------------------
Returns two arrays, the first containing the elements of _enum_ for
which the block evaluates to true, the second containing the rest.

(1..6).partition {|i| (i&1).zero?} #=> [[2, 4, 6], [1, 3, 5]]



> It's also hard to find modules or classes that aren't built in. I think
> I found the 'postgres' module in the RAA, but it isn't exactly an
> application, it's more of a library.
>
> I have some idea about what "gems" are but it's confusing how they fit
> into the big picture.


RAA is the main registry for Ruby projects/modules/libs -- it is searchable,
and categorized. RAA doesn't actually host projects though, but rubyforge
does (most things there are registered on RAA). Gems and RPA are two
packaging schemes that try to make it easier to automate package retrieval
and installation (along with other goals). RPA operates more like Perl's
CPAN.pm install shell, it has 150+ packages at the moment.

http://raa.ruby...
http://rubygems.rubyforge.org/wiki/wiki.p...
http://rpa-base.rubyforge.org/wiki/wiki.c...

> I really like the language and community, but perhaps the community
> resources put off some of the less determined people from getting into it.

There have been some hints that ruby-lang may get a face-lift to help
address this issue.

regards,
andrew

--
Andrew L. Johnson http://www.s...
Where the hell are my fries, kid?
-- Tom Christiansen, on comp.lang.perl.misc

Thursday

1/28/2005 1:29:00 AM

0

Jeff Davis wrote:
> ...
> Can someone let me know where I can find some of these resources?
> ...

Taken from http://www.rubygarden.org/ruby?Ru...


Interactive ruby resources:
---------------------------

irc://irc.freenode.net/ruby-lang - the #ruby-lang channel is popular.
More info at RubyOnIRC

http://www.ruby-for... - a forum for ruby novices to ask questions

news://comp.lang.ruby - the ruby newsgroup


Ruby websites:
--------------

http://www.ruby... - ruby home

http://www.rub... - ruby docs and online reference

http://www.ruby... - rubyforge ruby projects

http://raa.ruby... - ruby application archive

Ruby Code Examples and Snippets:

http://pleac.sourceforge.net/p... - ruby pleac

http://www.rubygarden.org/ruby?RubyOnli... - ruby cookbook


Popular ruby and ruby-related projects:
----------------------------------------

http://rubyinstaller.rubyforge.org/wi... - ruby installer for Windows

http://rubyforge.org/projects... - rubygems ruby package manager

http://www... - ruby 1.8 includes built-in yaml support

http://www.rubyon... - web framework in ruby

http://rubyforge.org/project... - wiki in ruby