grub-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Copyright lines not being updated!


From: Robert Millan
Subject: Re: Copyright lines not being updated!
Date: Mon, 4 May 2009 22:31:50 +0200
User-agent: Mutt/1.5.18 (2008-05-17)

On Tue, May 05, 2009 at 03:44:27AM +0800, Bean wrote:
> Hi,
> 
> git users can add this at the beginning of .git/hooks/pre-commit to
> run the copyright update test before committing:
> 
> L1=`git diff --cached --stat 2>/dev/null | gawk '{ if (($2 == "|") &&
> ($3 > 5)) print $1}'`
> L2=`grep -lie "Copyright (C).*\(199[0-9]\|200[^9]\) *Free" $L1 2>/dev/null`
> 
> if test ! -z $L2 ; then
>       echo You should update copyright information for the following files:
>       git diff --cached --stat $L2 2>/dev/null
>       exit 1
> fi

Note that copyright lines don't _always_ have to be updated.  It's
detrimental to do it when there's no need (bogus copyright assertions
weaken the legitimate ones).

-- 
Robert Millan

  The DRM opt-in fallacy: "Your data belongs to us. We will decide when (and
  how) you may access your data; but nobody's threatening your freedom: we
  still allow you to remove your data and not access it at all."




reply via email to

[Prev in Thread] Current Thread [Next in Thread]