Source changes should include date of change

Patrick Schluter Patrick.Schluter at bbox.fr
Sat Sep 8 15:52:53 UTC 2018


On Saturday, 8 September 2018 at 12:36:01 UTC, Paul Backus wrote:
> On Saturday, 8 September 2018 at 11:29:15 UTC, Josphe Brigmo 
> wrote:
>> Um, I didn't say don't use Git!
>>
>> Your illogic is that you believe that one can have only one or 
>> the other when one can have both. Hence, you are excluding a 
>> completely valid addition. You think it is an alternative. You 
>> are wrong. Please think about the question before you answer 
>> next time so that you don't get in the habit of doing it. No 
>> one said that Git couldn't be used and telling me to use it is 
>> very arrogant of yourself.
>>
>> The fact of the matter is that dates in source code will help 
>> when git is not available and one only has the source code.
>
> Git does a better job of tracking history automatically than 
> anyone could ever realistically do by hand. So not only would 
> date comments be useless duplication of work, they'd be useless 
> duplication of inferior quality to the original.
>
> It would be like keeping a horse at your house at all times, in 
> case your car breaks down. Even if it's occasionally useful, it 
> is not worth the constant maintenance costs of feeding the 
> horse, cleaning the stable, etc.
>
> If your car breaks down, you find a way to get it fixed. If git 
> isn't available to you, you find a way to make it available.

Interactive programs like GitExtension show exactly the the date 
of each line with the git blame view.
Visual Studio Code with the D extension also shows the commit 
info when hovering over the code.
There are a lot of nice way to use the git info to get the date 
of the line.

Dates in the comments are utterly useless. They are imo even 
counter productive. The information has not bearing with the 
actual code.
There is no point in putting dates in the comments when the code 
is managed by git.


More information about the Digitalmars-d mailing list