diff options
| author | Wolfram Schneider <wosch@FreeBSD.org> | 1996-06-30 11:51:41 +0000 |
|---|---|---|
| committer | Wolfram Schneider <wosch@FreeBSD.org> | 1996-06-30 11:51:41 +0000 |
| commit | 141f35e88e5c6a7463ced608816bf743eee17398 (patch) | |
| tree | 2e1816e854ba28fc764ffc6f0fba24e6108c2d5b /gnu/usr.bin/cvs | |
| parent | 6d41a714b29c9aa9a0dde5dd2b793229991ce1e8 (diff) | |
Notes
Diffstat (limited to 'gnu/usr.bin/cvs')
| -rw-r--r-- | gnu/usr.bin/cvs/contrib/README | 1 | ||||
| -rw-r--r-- | gnu/usr.bin/cvs/contrib/checklog.pl | 34 |
2 files changed, 35 insertions, 0 deletions
diff --git a/gnu/usr.bin/cvs/contrib/README b/gnu/usr.bin/cvs/contrib/README index e84b1761c0b1..a999aed34514 100644 --- a/gnu/usr.bin/cvs/contrib/README +++ b/gnu/usr.bin/cvs/contrib/README @@ -88,3 +88,4 @@ Contents of this directory: clmerge A perl script to handle merge conflicts in GNU style ChangeLog files . Contributed by Tom Tromey <tromey@busco.lanl.gov>. + checklog.pl extract your commits from commitlogs archive diff --git a/gnu/usr.bin/cvs/contrib/checklog.pl b/gnu/usr.bin/cvs/contrib/checklog.pl new file mode 100644 index 000000000000..fab1c8f5d61f --- /dev/null +++ b/gnu/usr.bin/cvs/contrib/checklog.pl @@ -0,0 +1,34 @@ +#!/usr/bin/perl +# Copyright (c) Wolfram Schneider <wosch@freebsd.org>. June 1996, Berlin. +# +# checklog - extract your commits from commitlogs archive +# +# checklog username /a/cvs/CVSROOT/commitlogs/*[a-y] +# zcat /a/cvs/CVSROOT/commitlogs/*.gz | checklog [username] +# +# $Id: checklog.pl,v 1.2 1996/06/27 12:54:25 wosch Exp $ + +# your name or first argument +if ($ARGV[0]) { + $name = $ARGV[0]; shift @ARGV; + warn "Is this really a username: `$name' ?\n" + unless $name =~ /^[a-z0-9]+$/; +} else { + $name = `whoami`; chop $name; +} + +# date string 96/02/18 10:44:59 +$date = '[0-9][0-9]/[0-9][0-9]/[0-9][0-9] [0-9][0-9]:[0-9][0-9]:[0-9][0-9]'; + +$flag = 0; +while(<>) { + if (/^[a-z]/) { # start of a commit + if (m%^$name\s+$date$%o) { # it's *your* commit + $flag = 1; + } else { + $flag = 0; + } + } + + print if $flag; +} |
