HACKER Q&A
📣 znpy

Why is Ruby so poorly documented?


I need to pick up ruby for work, and headed to ruby-lang.org.

I've mostly worked with Python so far, and my best companions have been the Python tutorial (https://docs.python.org/3/tutorial/index.html), the library reference (https://docs.python.org/3/library/index.html) and the language reference (https://docs.python.org/3/reference/index.html).

I was very surprised to see that on ruby-lang.org there is practically no equivalent o the Python tutorial. The closest thing is the on-line version of the pickaxe book (https://ruby-doc.com/docs/ProgrammingRuby/) which is about Ruby 1.6, released in September 2000.

There are a myriad of other small or smaller resources (koans and stuff) but no just-sit-down-and-read-all-this document.

So the question is... Why is ruby so poorly documented? How is one supposed to learn ruby nowadays, properly ?


  👤 rgoulter Accepted Answer ✓
The "documentation" page lists 6 different "getting started" guides. https://www.ruby-lang.org/en/documentation/

It also links to https://try.ruby-lang.org/ which has a series of quick tutorials to go through learning Ruby in the browser, without having to install anything on your computer.

I don't think "poorly documented" is a fair description of those resources.


👤 teeray
There’s a brand new Pickaxe for 3.2: https://pragprog.com/titles/ruby5/programming-ruby-3-2-5th-e...

I learned from it for 1.7 ages ago, and I’d still recommend it (especially since it’s been updated).


👤 thiago_fm
Ruby is far from being poorly documented. It just isn't documented in the way you are typically used to, coming from Python.

There are quite few initiatives that tried to do what the Python tutorial, but ultimately failed or didn't get enough traction in the Ruby land.

The best method in my opinion to learn Ruby is to just try to code a Rails app and learn along the way, but if you like to stop and read and learn the language constructs, the Pickaxe book is the best. It isn't stuck in 1.6 as you've mentioned, it was just released for Ruby 3.2.

There are so many other Ruby books as well, like eloquent Ruby and so on.

Another solution is do a course on pluralsight or any other website, I bet there are many teachers and tutors that will help you nail down the language's basics.

BTW, just showcasing how the Ruby community can document well... the Rails documentation is the best documentation I've ever read. It's concise and presents basically every concept of the framework with practical examples.

I'd say Rust and Elixir have also good documentation, but I've never came across with a so well thought out doc as the Rails one.


👤 mikerg87
In the dawn of Ruby, the pragmatic programmers guide to ruby was how I got started. It’s free online now :

http://ruby-doc.com/docs/ProgrammingRuby/


👤 evolve2k
A couple of quick Ruby resources for python folk.

To Ruby From Python https://www.ruby-lang.org/en/documentation/ruby-from-other-l...

Ruby tutorial for Python programmers: How to make the switch https://www.educative.io/blog/ruby-tutorial-python-programme...


👤 senthilnayagam
I discovered ruby in 2004 and fell in love with it.

tell me your current programming skills and then I can suggest you to build something meaningful and learn the language features along with it.

text file processing connecting to database and generate reports processing emails build a static site generator build a simple website with sinatra build a large app with ruby on rails

my twitter id is same as HN id, I can share more pointers, good code to read to master your skills


👤 herbst
From my experience there are 2 ways people got into Ruby.

1. By learning Ruby

Don't mind how old the guide is. Ruby is still Ruby, sure plenty of things are better now but the old syntax is still supported and used. I don't see an issue with learning from poignants guide today as I did back then.

You should be able to run 99% of all tutorial examples without modifications in a modern ruby interpreter.

2. Headstarting into Rails

Just start building CRUD apps after any recent tutorial. Video or text whatever you prefer. Ruby is shining trough and after some time you'll learn what's Ruby, what's Rails and what is just you.


👤 sweetgiorni
This looks like Ruby's equivalent to the Python docs:

https://docs.ruby-lang.org/en/master/index.html


👤 quags
There are people who are great at coding. There are people who are great at documentation. They are not always the same. Working with open source software - I find the ones who work on documentation tend to not be adding the code.

👤 juanse
I have to agree with this. An also, Rails.

There are some API methods very poorly documented and all you can do is try to get lucky for a 2007-2009 comment in it.


👤 anonreeeeplor
I remember trying to learn Ruby on Rails. I read all the books and started playing around with scaffolding. It was giving me problems and I was talking to a senior developer from the community about it and he said: “Everyone knows you don’t use scaffolding, no one does that.”

It was super confusing because ALL of the documentation EVERYWHERE said to do it that way, but in the community of pro developers, they all knew it was just a stunt feature to make it easy to onboard.

I think perhaps it is rooted in the nature of how Ruby was created, more of a an amorphous mob of hobbyist hipster pot smoking ultra laid back creative engineers who dropped out of high school versus “.NET” or Java which are backed by major enterprises.