How I learnt git pull requests

That was an amazing experience that ultimately turned into a git pull request into Midje – a test framework for Clojure.

I’m working on a side project – librarian-clojure – which aims at providing a CRUD-like web application to manage books and when a colleague Konrad Garus cloned it to his own repo where he made some changes to, I was asking myself how to merge his changes with the repo I work with.

The project librarian-clojure is also aimed to let me learn Clojure and its web ecosystem, git and GitHub, and finally Heroku. Lots of stuff I’ve never worked with before. Git is amongst them.

So, I was wondering about merging the changes with the repo of mine. I’ve been hearing about pull requests on GitHub, but didn’t have time to grasp it. I emailed Konrad asking about it and hoping he would know the answer. He did. Early in the morning next day I found a pull request. Just at the same time when I pulled his changes to my repo and pushed them to GitHub. I remember I had to use git stash, too, while applying his changes. Quite intensive git self-learning.

The other day I was reading a blog post of Sean Corfield – Testing your project against multiple versions of Clojure where he described how to unify a set of dependencies in a Clojure project. I did use it in the librarian-clojure project and also found a note in Midje’s project.clj (the version I’m reffering to is this version of project.clj):

“;; TODO: Alex Jan 29, 2012 – figure out how to not duplicate these deps”

That was a call to action for me! :)

I had known how to do it so it was a matter of copying and pasting the solution I had found in Sean’s blog post. That’s how a pull request of mine was born. It didn’t take long before Alex accepted the change and it’s now a part of Midje.

It’s rewarding when a change doesn’t take much but stays longer.

Be Sociable, Share!
This entry was posted in Frameworks, Languages.

Leave a Reply

%d bloggers like this: