Showing posts with label pm. Show all posts
Showing posts with label pm. Show all posts

Wednesday, October 31, 2007

Using Git with Lighthouse

I wanted to set up Git integration with Lighthouse. The requirements for this was a bit different from the regular SVN integration, since in SVN every commit goes to a central repository, while Git is distributed. For the projects we wanted to integrate with Lighthouse, we use a shared Git repository which acts like the "main" repos. So when our local commits and changes gets pushed to the main repos, we want it to send a new changeset to Lighthouse, which should include the commit messages of all the new revisions since the previous push. A bit more complex than the Svn use case, but luckily Git provides some nice tools that made it quite easy. Google told me that some other guy made something similar a few days ago. However, his solution uses a post-commit hook, and thus sends every single commit to Lighthouse. Which wasn't acceptable for us, since we do a lot of small atomic commits localy. And it works against one of the nicest Git features: quick and easy branches for experimenting, since all the experimental commits would have been exposed to Lighthouse and filled up the overview screen. Summed up, we wanted to be able to make multiple local commits, and then send them as a "revision bundle" to Lighthouse and the main repos.

I solved this by setting up a both post- and pre-receive hooks on the main repos. I suspect that the pre-receive hook can be avoided, but I did the simplest thing that could possibly work. The pre-receive hook saves the current (pre-push) revision to a temporary text file, so it can be used by the post-receive hook. The post-receive hook runs a Ruby script. Most of it is taken from the script in the earlier link. The coolest line goes like this:


commit_log = `#{GIT} rev-list --pretty=short "#{oldrev}..#{newrev}" | git shortlog`


It sums up each authors commits, and shows the commit messages from each of the commits. (You can see this in action on the screenshot at the top of this post) Perfect. The script isn't as complete or elegant as it should be, but it works for now. I will edit it if I come up with something better. If anyone else makes improvements to this script I would love to hear about it (please leave a comment here, or ship me an email)!

Pre-receive hook: http://pastie.caboo.se/112536
Post-receive hook: http://pastie.caboo.se/112535

Tuesday, October 30, 2007

Choosing a project management system

Last week we were starting up a couple of small projects for some clients. I saw that as a great opportunity to review our choice of project management system. We were currently using Retrospectiva, a open source rails project. It does the job okay, but it isn't exactly very pretty, and the usability kinda sucks. This is supposed to get improved. Anyway, letting clients into Retrospectiva just didn't feel right. Oh, and currently Retrospectiva only supports subversion. And since we've transitioned completely to Git, thats a problem for us.

So I went looking for a substitute. I looked a bit at a new Rails app named WhoDoes. Its pretty cool, and I really wanted to like it since its extremely cheap compared to Lighthouse. It wasn't quite "it" tho. The biggest problem: it lacks a very basic PM requirement: knowledge capture. You really need to have an external wiki or something, since it doesn't even have simple pages/messages like Lighthouse. But I bet this app will improve in the future, so it's something to look out for. So we ended up with Lighthouse, which has a really really beautiful UI. And it's dead easy to use: everything is a ticket. Client-safe, and a whole lot more fun to use than Retrospectiva! We even got Git integration working, which I will write about next.