[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y ] [Search | Free Show | Home]

/g/ I'm learning ruby/ror and need good books. Anyone can

This is a blue board which means that it's for everybody (Safe For Work content only). If you see any adult content, please report it.

Thread replies: 53
Thread images: 6

File: ruby.png (210KB, 1200x1200px) Image search: [Google]
ruby.png
210KB, 1200x1200px
/g/ I'm learning ruby/ror and need good books. Anyone can post titles or resources?
>>
stop learning rubty and learn go insteaD
>>
Learn Crystal
>>
Well Grounded Rubyist
Eloquent Ruby
Metaprogramming Ruby
The Rspec Book
Programming Ruby 1.9: The Pragmatic Programmers’ Guide
The Ruby Programming Language
>>
>>62466614
Thanks
>>
>>62466630
ruby-doc.org if you ever need to look things up

wish you luck anon
>>
>>62466543
>Telling OP to learn something worse
>>
I guess I'll ask here. What can Ruby do that other frameworks with more common languages won't?
>>
>>62466614
These are all good.
Also:
Hartl's free Rails tutorial.
Official RoR guides.
Google's Unofficial Ruby Usage Guide
Why's Poignant Guide to Ruby
Make sure you understand all the Array, Hash, and Enumerable methods.
The Ruby Association Examinations have a list of what they cover, which is what's generally important to know.

Good luck anon. Ruby is a joy to program.
>>
>>62466727
>Ruby
>Not common

Queef again?
>>
>>62466727
I wouldn't say there's anything only Ruby can do.

Ruby is just a really fun language to work in. It's like a better-designed Python with elements of Smalltalk, Perl, and Scheme.
Rails has an extensive and stable ecosystem, and integrates very tightly into Ruby due to Ruby's metaprogramming capabilities. It's an opinionated framework, so if you take the time to learn how it works you can crank out websites incredibly quickly.

The only language that I think could really give Ruby a run for its money is Clojure, but Clojure's ecosystem is unstable and its documentation isn't very good.
>>
>>62466847
ror is short for ruby on rails, mentioned in first post lol
>>
>>62466532
don't get memed, there's no reason to learn ruby in 2017
>>
>>62467007
There is one, RoR
>>
>>62466846
How is Clojure's ecosystem unstable? And really the docs aren't any worse than any other lisp.
>>
>>62467133
Was in a hurry and used the wrong word. I meant the ecosystem is still changing fairly quickly.
Yeah, Clojure's documentation is pretty good for a Lisp, but isn't as good as its competitors in webdev.
That said these days I use Clojure almost exclusively for personal projects. It's a fantastic language.
>>
>>62466532
Both of these anons are good suggestions:
>>62466614
>>62466765
I would add to the list Practical Object-Oriented Design in Ruby.
It's not just about Ruby, but about clean and simple OO design more generally, and avoiding the traps of OO circa 00's era Java and .NET, with their overengineered enterprise shit and pattern wankery. The fact that the book is written in Ruby gives you great examples of how to apply the principles presented.
>>
>>62466846
I'm a scientist and have no formal CSU training. I've used python and dabbled in Ruby. Ruby felt much more intuitive and was much more fun. However, virtually everything I need is implemented in python and not at all or poorly in ruby. And the time you save in ruby due to it being more intuitive, you lose again by looking through the poor documentation when you're stuck. It would have been nice if ruby would have been the language to go for science, but I guess python was earlier.
>>
I'm not one to recommend codeacademy, but due to the very hands on and easily memorable nature of Ruby, I was able to learn from there.
>>
You purport to be a programmer but can't be bothered to google up something?
>>
>>62467787
once upon a time anon gave me a link where most of pref books were on one site, thats why
>>
>>62467339
I'm still struggling to learn it. Anytime I see a thing I could use macros with, I then spend an hour trying to figure out the right way to place the quotes.

Most recent example is with the tests for an IRC framework. I want to write tests to ensure that incoming strings are parsed correctly, and this involves a shitload of boilerplate. Easily condensed down to a one liner.. or so I thought anyways.

Example:

(fact "ping messages"
(let [splitmsg (stringToIRCMessage ":PING example.net")]
(get splitmsg :type) => "PING"
(get splitmsg :destination) => nil
(get splitmsg :message) => "example.net"
)
)


Where in my ideal world, I could just write:

(factCheckParse ":PING example.net" {:type => PING, :destination => nil, :message => example.net}) 


and spit all that out. I've yet to figure out the right way to write the macro...

(defmacro factCheckParse [message results]
(let [splitmsg (stringToIRCMessage ~message)]
(for [k# (keys ~results)]
(k# results) ~=> (k# splitmsg)
)
)
)


This doesn't work.
>>
>>62466532

"The well-grounded Rubyist" in an excelent ressource for learning.

For Rails "Rails 4 in action" is nice (there is no Rails5 version of the book, but it also works with Rails5).


>>62467915

>Where in my ideal world, I could just write:

Haha, you seem like the typical Rubyist..

Once you get some Ruby experience you are forever spoiled from it's beautiful and logical syntax. So when I thought about learning a new language I thought about the following:
-Scala
-Node
-Haskell
-Clojure
-Elixir

I decided to evaluate each of them for a short while and decide after getting a good impression. Here's my thoughts so far:
Scala seems nice, but is an ungly mess underneath.
Node.. well, it's not bad but it's not really beatiufull either.
Haskell.. maybe someday, but not yet. It's also too far away from webdesign.
Clojure was a really nice experience, I spend two weeks doing "hello world"-like stuff. But at the end of the day it's still Java. And I'm not sure about the microservice way of doing things. Ring is not bad, but I'm not 100% convinced yet. Sometimes I struggle with that low level way of doing things. Not sure if I will follow that route, but Clojure is definitely one of my favorites so far..

Next things to look at are Elixir. Or recently I thought about Common Lisp.
Elixir is somehow a logical next step after Ruby, considering the influence of Rails on Phoenix.
Lisp would also be great fun, since Ruby is IMHO the most "Lispy" language that is not a real Lisp itself. But I ahve to say I am only an mediocre Scheme beginner, no idea if CL is the right choice for me.

Anyway, I will take my time and in the meantime I just keep on going the Rails way.
>>
>>62466532
Effective Ruby: Rough Cuts
super great honestly I loved it
can post pdf if you want
>>
Why are Ruby guys such bros ? Serious question
>>
File: 1466348749996.png (13KB, 736x547px) Image search: [Google]
1466348749996.png
13KB, 736x547px
>>62468317
Not that anon but I would really appreciate it if you do.
>>
>>62468590
Bottom file in this list
volafile.org
/r/kUFzLJ

Nice gondola by the way
>>
>>62466532
>>62468590
Try team treehouse guys if you want a quick splash course for novices.
I usually start with them, then pickup the books.

Curious, what are you learning ruby for? What do you plan on building?

Im a python and java guy myself and haven't seen a huge "this is the reason to pickup the language".
>>
>>62468547
because dey gay
>>
>>62468547
The guy who made Ruby is a total bro, and we all strive to follow his example. We have a saying that Matz is nice, so we are nice.
Ruby IRC/Slack is super friendly, and contributing to the language is a positive process.

>>62469889
It's not gay if you say "no hom-functor" first.

>>62468206
I've been using Clojure to clean and analyze large data sets, and wow is it good at it.
I had a very positive impression of Elixir. I'll definitely be learning more at some point.
I was learning CL and I switched to Clojure. There was a large amount of what seemed like old cruft, and it didn't fit my needs very well.

>>62466532
Check out the ebook thread on Lainchan's lambda board. It has a lot of the books here posted.
>>
>>62469857
0x0.st / 7E1.pdf
>>
>>62468206
You're not wrong. I mostly write Python nowadays, but damn if I didn't fucking love Ruby.
>>
>>62469888
the reason is basically sinatra and eruby. Some other things like how easy it is to work with classes, write unit tests, etc.. are nice, but not really worth picking up the language for
>>
File: distress.jpg (118KB, 500x375px) Image search: [Google]
distress.jpg
118KB, 500x375px
>>62469888
Baby's first language for me, I'm incapacitated for a year might aswell learn something new instead of doing nothing.
>>
Ruby Monk is really good if youre not sure about Ruby and want to get a quick feel of the language within a half hour
https://rubymonk.com/
>>
>>62470392
Python very nicely replaces those with Flask and Mako.
>>
>>62470902
Yes it absolutely does, unfortunately I've had the displeasure of having to use Flask with Jinja and the unusable clusterfuck known as flask-sqlalchemy and it was really unenjoyable
>>
File: RUM_coverfront.png (170KB, 400x529px) Image search: [Google]
RUM_coverfront.png
170KB, 400x529px
>>62466532
Best book on Ruby, by far. Not for starting out though, more for when you get to a point where you want to know "why".
>>
>>62466532
>learning a dead SJW language
>>
>>62467698
I think Python will eventually get phased out and replaced by Go.
>>
>>62471946
I was thinking about getting the book? How good is it?
>>
>>62472699
Cretin.
>>
>>62472777
It seems unlikely.
>>
>>62467698
What you think of Julia eventually replacing Python?
>>
>>62473621
>Julia
Literally who
>>
>>62473639
The supposedly goto scientific programming language of the future. Dynamic, MATLAB-like syntax with inspirations from Lisps (among others macros) yet Python-cally easy to dig in, fast without optimizations.
>>
>>62469888

>I'm a python and java guy myself and haven't seen a huge "this is the reason to pickup the language".

Oh well..
Matz said, Ruby was made for "programmer happiness". That's the main reason. A lot of things in the language that make Ruby extremely slick:
-Easy peasy functional programming. Map/Reduce/Filter feel naturally and you will thworing lambdas arround without even noticing
-Blocks/Procs
-Very powerful basic language constructs. You can basically "rebuild" half of Ruby yourself with some basic elements
-Amazing data structures and Iterators. Often Python people say "but you can do this only for arrays!", but in Ruby everything that can be iterated on is somehow an array.
-Powerful RegEx's that can be used everywhere, (i.e. even in switch/case statements or just at strings: "bla-hi-blahb"[/-.{2}-/])
-Ruby has open classes, you can bend the language to your needs or simply create a new language ("domain specific language") like in Chef or Rails
-Super intuitive syntax.
-Great for scripting.
-It's just fun and comfy. Similar to Perl you can write amazing code only to find that there is an even simpler solution. Ruby makes it fun to find out about hidden syntactic sugar, you can get down to very brief syntax, expressing only what you want to.

Also Ruby has an amazing power level deep inside. You have crazy abstractions like "continuations" (only Ruby and Scheme have them). You can always talk with the shell simply by putting things into backticks. And so on.

>>62467698

It's not necessarily an either/or-decision.
Write Python when you have to, write Ruby when you can.


>>62472777
>>62473621

I think Python is here to stay.
It just has enough traction and a shitload of mature libraries. And it's not bad at all.

I can see Julia or Go for smaller research projects, and Go (of course) for servers.

I love my Ruby and the level of productivity, but I can't say I'm not jelly about Go-channels and compiling to binary files.
>>
Where could I find good Ruby open source projects I could contribute to and learn at the same time?
>>
>>62466532
google how to make a chat server with rails and youll be a pro by the end of it. Also ruby is 50-100x slower than straight c, and the web industry is moving away from it so keep that in mind if your planning a career.
>>
>>62466532
"The Ruby Cookbook" is always a good option after you read other books. And welcome to the confy world of Ruby.
>>
>>62472783
Its good if you want to learn how to hand code a simple Ruby compiler and know how Ruby is implemented at low level
>>
>>62474776
Kys
Thread posts: 53
Thread images: 6


[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y] [Search | Top | Home]

I'm aware that Imgur.com will stop allowing adult images since 15th of May. I'm taking actions to backup as much data as possible.
Read more on this topic here - https://archived.moe/talk/thread/1694/


If you need a post removed click on it's [Report] button and follow the instruction.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com.
If you like this website please support us by donating with Bitcoins at 16mKtbZiwW52BLkibtCr8jUg2KVUMTxVQ5
All trademarks and copyrights on this page are owned by their respective parties.
Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
This is a 4chan archive - all of the content originated from that site.
This means that RandomArchive shows their content, archived.
If you need information for a Poster - contact them.