comparison lib-src/rcs2log @ 535:4b75abb93479

Don't munge $* when getting date from ChangeLog.
author Paul Eggert <eggert@twinsun.com>
date Wed, 05 Feb 1992 17:25:10 +0000
parents 6f7abc0e1f10
children efa0c124c178
comparison
equal deleted inserted replaced
534:6f7abc0e1f10 535:4b75abb93479
1 #!/bin/sh 1 #!/bin/sh
2 2
3 # RCS to ChangeLog generator 3 # RCS to ChangeLog generator
4 4
5 # $Id: rcs2clog,v 1.2 1992/02/05 04:29:40 eggert Exp $ 5 # $Id: rcs2clog,v 1.2 1992/02/05 04:31:18 eggert Exp eggert $
6 6
7 # Generate a change log prefix from RCS/* and the existing ChangeLog (if any). 7 # Generate a change log prefix from RCS/* and the existing ChangeLog (if any).
8 # Output the new prefix to standard output. 8 # Output the new prefix to standard output.
9 # You can edit this prefix by hand, and then prepend it to ChangeLog. 9 # You can edit this prefix by hand, and then prepend it to ChangeLog.
10 10
33 # Log into $rlogout the revisions checked in since the first ChangeLog entry. 33 # Log into $rlogout the revisions checked in since the first ChangeLog entry.
34 34
35 datearg=-d'>1970' 35 datearg=-d'>1970'
36 if test -s ChangeLog 36 if test -s ChangeLog
37 then 37 then
38 date=`sed 1q <ChangeLog` || exit 38 e='s/^\(...\) \(...\) \(..\) \(..:..:..\) \(....\) .*/\1 \2 \3 \4 \5/p; 1q'
39 set x $date; shift 39 date=`sed -n "$e" <ChangeLog` || exit
40 datearg="-d>$1 $2 $3 $4 $5" 40 case $date in
41 ?*) datearg="-d>$date"
42 esac
41 fi 43 fi
42 44
43 rlogout=/tmp/chg$$ 45 rlogout=/tmp/chg$$
44 trap exit 1 2 13 15 46 trap exit 1 2 13 15
45 trap 'rm -f $rlogout; exit 1' 0 47 trap 'rm -f $rlogout; exit 1' 0