random thoughts on software engineering

An aspiring software craftsman journey

How To Use Version Control Systems The Wrong Way

I had the chance to work for different organizations and noticed that VCS are often misused. Here is why:

1. Using VCS to store artifacts binaries

Please stop using Subversion or Git to store your Jars! VCS are source code repositories not binaries repositories.

There are other tools designed specifically for that like nexus, artifactory or bintray. They do their job very well. So why do you store hundreds of dependencies along with source code if you can simply get them from a binaries repository?

If you are using Ant, you are somehow forced to do it, but when would you consider moving to Maven or Gradle :smile: ?

There are even folks using GitHub as maven repositories! Sonatype provides this service for free. So why using the wrong tool for the job?

2. Storing non “diffable” file formats into VCS

VCS is all about being able to track and see changes from one version to another. If you are not able to see what has changed from v1 to v2, you are probably using a VCS simply to store files. In this case, may be you don’t need a VCS at all. Simply use your hard disk which is good at it.

For instance, if you store MS-* document types, how can you compare two versions of the same document? You should use textual data format to be able to view difference between two versions. There are dozens of simple yet powerful textual formats to write documentation: Asciidoc, Markdown, Textile, etc to name a few.

So please stop using vendor-specific data format that are “non-diffable”.

3. Using photos as documentation under VCS

This is a common practice: after a design brainstorm, you take a photo of the board and put it under VCS.

How can you diff photos? What if your design changes from v1 to v2?

This is the same as point 2, but I do believe that using photos as documentation is simply wrong.


To sum up, use the right tool for the right job. If you have seen other bad practices of using VCS, please share them in comments.