Source Control Checkin Comments at Top Of Source Files

Posted by James Wiseman on Stack Overflow See other posts from Stack Overflow or by James Wiseman
Published on 2010-05-17T13:49:30Z Indexed on 2010/05/17 13:50 UTC
Read the original article Hit count: 419

I've noticed a discrepancy with some source files in our system whereby some contain source-control checkin comments, and some do not. These comments are added automatically to the top of the file when it is checked in:

    * $Log:   //vm1/Projects/Morpheus/Sleep.bdy-arc  $
--
--   Rev 1.14   Apr 14 2009 15:32:52   John Smith
--Fixed bugs 2292 and 2230.

This seems to have been quite prevelant in all the compainies with which I have worked, but I must confess that I struggle to see the point. Generally the comments aren't that good, are ofen left by people who have long since departed, and even when they are of a high standard it is difficult to tie them to physical code changes.

It also strikes me, that you are physically changing the file that you are checking in. Now, this may not be such a problem with files that will be compiled, but could be a disaster with others, e.g. JavaScript files.

So really, my query is what was the motivation in concept behind providing this functionality in the first instance? Does anyone actually find these comments useful?

Also, I would be curious to know if this was feature that is commonly supported within Source Control systems. I am aware of it with PVCS, VSS and Subversion (Subversion Keyword Substitution), however I wonder if it is also available in some of the more popular DVCSs.

Your help, as always is much appreciated.

© Stack Overflow or respective owner

Related posts about source-control

Related posts about keyword-expansion