Fork me on GitHub

Tag Ruby

The Truth About Gemspecs

There are still many folks who know shit about gemspecs, who misunderstand what gemspecs are good for or don't have a clue how to work with them. So let me explain to you and show some tricks how to use them effectively.

I'm So In Love with Enumerable#inject

Enumerable#inject is the most flexible method for iterating collections with awesome possibilities. Let's take a look on some examples where it actually fits better than other Enumerable methods.

Wake up guys, Ruby 1.9 is here!

I'm disappointed how slowly Ruby community adopts the new Ruby 1.9. Oh wait, it's not new at all, it's more than a year old now! There is still significant amount of gems which aren't 1.9-compatible, my collegueues are asking me why we should upgrade to Ruby 1.9 and for Rubinius core team has compatibility with 1.9 so low priority that they didn't accept my patches for 1.9 compatibility even if I asked then 3 times.

Why You Don't Need OOP in JavaScript (So Much)

After I did some research on OOP in JavaScript, I realized I don't need it so much. I'm used to do pretty much everything via OOP, since it's the way how Ruby, my primary language works. But JavaScript is different.

CommonJS Module System in Ruby

I really like the CommonJS module system, which is explicit, rather than implicit as Kernel#require in Ruby. So rather than putting everything into the global namespace, require in CommonJS simply returns an object which contains the stuff you explicitly exported from the required file. For example:

DRY Your YAML Files Up!

It's basically a simple inheritance pattern in YAML:

Pending Examples via NotImplementedError in rSpec

NotImplementedError can be sometimes really helpful. Unfortunately rSpec shows them as a failure, but aren't they just the exact equivalent of a pending message?

My Presentations about Freelancing & Messaging

Currently I'm on visit in Czech Republic where I'm originally from and I'm doing some talks in here. I talked about freelancing for Prague Ruby group and for TechSpring in Olomouc and about messaging for Masaryk university.

Padrino and Template Inheritance

Rango was the first framework supporting template inheritance in Ruby. Now thanks to the template-inheritance gem and its new Padrino adapter you can have all the inheritance goodies in Padrino!

Custom Gems in Gemfile

Switching between your custom libraries from your local directory and from RubyGems.org can be a real pain. Fortunately with Bundler it's getting much easier.

About

RSS

All Posts Ruby

Tags

GitHub projects

Twitter @botanicus

Recent Comments