mirror of
https://github.com/postgres/postgres.git
synced 2025-07-05 07:21:24 +03:00
Make comma optional for copyright text change.
This commit is contained in:
@ -1,14 +1,14 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
# $PostgreSQL: pgsql/src/tools/copyright,v 1.15 2008/01/02 02:36:18 momjian Exp $
|
# $PostgreSQL: pgsql/src/tools/copyright,v 1.16 2009/01/01 18:21:56 momjian Exp $
|
||||||
|
|
||||||
echo "Using current year: `date '+%Y'`"
|
echo "Using current year: `date '+%Y'`"
|
||||||
|
|
||||||
rgrep -l 'Copyright.*PostgreSQL Global Development Group' | while read FILE
|
rgrep -l 'Copyright.*PostgreSQL Global Development Group' | while read FILE
|
||||||
do
|
do
|
||||||
pipe sed 's/^\(.*Copyright (c) [12][0-9][0-9][0-9]\) \?- \?[12][0-9][0-9][0-9]\(, PostgreSQL Global Development Group.*\)$/\1-'`date '+%Y'`'\2/' $FILE
|
pipe sed 's/^\(.*Copyright (c) [12][0-9][0-9][0-9]\) \?- \?[12][0-9][0-9][0-9]\(,\? PostgreSQL Global Development Group.*\)$/\1-'`date '+%Y'`'\2/' $FILE
|
||||||
# handle cases where only one year appears
|
# handle cases where only one year appears
|
||||||
pipe sed 's/^\(.*Copyright (c) [12][0-9][0-9][0-9]\) \?\(, PostgreSQL Global Development Group.*\)$/\1-'`date '+%Y'`'\2/' $FILE
|
pipe sed 's/^\(.*Copyright (c) [12][0-9][0-9][0-9]\) \?\(,\? PostgreSQL Global Development Group.*\)$/\1-'`date '+%Y'`'\2/' $FILE
|
||||||
done
|
done
|
||||||
|
|
||||||
echo "Manually update doc/src/sgml/legal.sgml too" 1>&2
|
echo "Manually update doc/src/sgml/legal.sgml too" 1>&2
|
||||||
|
Reference in New Issue
Block a user