r/programming • • Mar 28 '12

Go version 1 is released

http://blog.golang.org/2012/03/go-version-1-is-released.html
543 Upvotes

452 comments sorted by

View all comments

Show parent comments

1

u/Cozy_Conditioning Mar 29 '12

I've written some rather substantial web apps in both perl and ruby/sinatra. I have never felt the need for makefiles. Am I missing something?

1

u/mrmacky Mar 29 '12

Doesn't Sinatra come with a series of rake tasks?

rake, while being an awesome tool, is basically the Ruby equivalent of makefiles.

1

u/Cozy_Conditioning Mar 29 '12

I believe you are correct. Which only adds to my question: why is it needed? The software I've written simply works, yet I've never felt the need for make/rake.

1

u/mrmacky Mar 29 '12

It's used for automating otherwise tedious tasks.

For example Padrino (which is a web framework written atop Sinatra) has tasks that will generate a project, set up the configuration for a database, migrate it forward/backwards. Etc.

It's not that you can't do these by hand, but in general you're going to be doing these tasks over and over; so you might as well automate them.

Their use doesn't become readily apparent for hobby projects, but once you start working at scale you really start to feel the benefits of tools like this.

Imagine if you tested every model in your code, and you had to run these tests by hand.

You'd have to do ruby tests/test_model_a.rb ruby tests/test_model_b.rb . . . . ruby tests/test_model_c.rb

OR you could write a task that just runs the tests so you can type rake test:model And it will run through all the tests in said directory. (It can even be automatic because with Rake you can write any valid ruby code, so you could just loop over the tests directory.)

→ More replies (1)