How to end up with 500,000 commits in your log

submited by
Style Pass
2021-06-19 00:00:15

I once worked for a company where they managed to create about half a million subversion commits in just 2 or 3 years, with about 3 developers working on it. I’ll leave it as an exercise to guess how they managed to do that :-)

They had a server in the office which ran the SVN server and OpenVZ to give every developer their own container running Apache and PHP, and that’s what you would use for development. How do you get your code to that container? NFS? SMB? FTP? Nah, that’s so boring! SVN is a much better tool for this!

The way this worked is that on every push the SVN server would run this PHP script to copy the changes to the right container based on the committer, the idea being that everyone only got their their own changes and not other people’s. You didn’t work off a martin branch – branches are for losers – you would always commit to the main trunk branch, which was the only branch people used. The script would look at the committer and copy all the files that commit touched to that person’s container. Every once in a while you manually updated your directory to get other people’s changes. Two people working on the same file at the same time was … unwise.

That PHP script was indecipherable with umpteemt levels of nesting. No one dared to touch it because it “mostly worked”, some of the time anyway. If it was the third Tuesday of the month.

Leave a Comment