RubyFlow : The Ruby Community Blog

Home   Submit   Sign Up   Log In   leaders   Twitter   RSS Feed  

gsmendoza — 7 posts

A few months ago, I suggested the Simple Git Branching Model and Best Way To Merge A (GitHub) Pull Request to Hendy, our CTO. We were using GitHub’s pull request feature for our code reviews, and as great as that feature was, it was turning our git history into, sorry for the pun, spag-git-ti. With the Simple Git Branching model, I was hoping for a more linear, more readable git history, with visible feature branches that can be easily reverted.

Hendy liked the idea, but felt that the workflow needed to be automated. With a script, accepting pull requests will be consistent and error-resistant.

And so, after several weeks of testing and usage, we’re happy to share git_pretty_accept.
We recently reorganized our Rails translation files. In order to continue using the config/locales directory, we made our changes in a temporary copy of the directory. We then wrote a test comparing the two directories to make sure no translation is lost. You can learn more at the Love With Food tech blog.
I recently discovered how to call Capybara/RSpec/Rails test helpers from a Page Object class without having to include all those test helper modules. Best of all, the solution is already part of the Ruby standard library. Check it out here.
Here's a workaround for making Cucumber steps local inside a scenario. It's simple and ugly, but it works. In the post, I argue that all this focus on writing Cucumber steps "correctly" is misplaced. I believe that if we allow steps to be local inside a Cucumber Scenario, this becomes irrelevant. I argue that domain language concepts should not be the responsibility of Cucumber Steps; instead, domain language concepts should be the responsibility of Cucumber Scenarios.
SwitchFile is a basic utility for jumping across files. With it, you can open the matching controller, helper, spec of a model file or whatever. You can configure the type of files it recognizes via a simple ruby configuration file.

Yeah, it's not entirely groundbreaking, but I needed this functionality for my editor. So here it is. Hope you like it!
Gitara is a Ruby DSL for generating Lilypond guitar tablatures. At 0.4.2, it's still a work in progress. But you should now be able to write some decent guitar tablatures with it (check out the examples!).

If you are a Ruby programmer, and you write guitar tablatures, and you have tried tab editors and lilypond, then... that makes two of us :P Hope to see you around!
Some tips to lessen the pain of adding email functionality to your Rails app.