Fix sed expression for BSD sed.
This commit is contained in:
parent
bdfbfde1b1
commit
980acc8329
|
@ -27,7 +27,7 @@
|
||||||
# Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
|
# Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
|
||||||
# Portions Copyright (c) 1994, Regents of the University of California
|
# Portions Copyright (c) 1994, Regents of the University of California
|
||||||
#
|
#
|
||||||
# $Header: /cvsroot/pgsql/src/bin/initdb/Attic/initdb.sh,v 1.180 2003/01/15 23:37:28 petere Exp $
|
# $Header: /cvsroot/pgsql/src/bin/initdb/Attic/initdb.sh,v 1.181 2003/01/21 10:11:52 petere Exp $
|
||||||
#
|
#
|
||||||
#-------------------------------------------------------------------------
|
#-------------------------------------------------------------------------
|
||||||
|
|
||||||
|
@ -1048,7 +1048,7 @@ $ECHO_N "creating information schema... "$ECHO_C
|
||||||
# Format version number to format required by information schema (09.08.0007abc).
|
# Format version number to format required by information schema (09.08.0007abc).
|
||||||
major_version=`echo $VERSION | sed 's/^\([0-9]*\).*/00\1/;s/.*\(..\)$/\1/'`
|
major_version=`echo $VERSION | sed 's/^\([0-9]*\).*/00\1/;s/.*\(..\)$/\1/'`
|
||||||
minor_version=`echo $VERSION | sed 's/^[0-9]*\.\([0-9]*\).*/00\1/;s/.*\(..\)$/\1/'`
|
minor_version=`echo $VERSION | sed 's/^[0-9]*\.\([0-9]*\).*/00\1/;s/.*\(..\)$/\1/'`
|
||||||
micro_version=`echo $VERSION | sed 's/^[0-9]*\.[0-9]*\.\([0-9]*\).*/0000\1/;t L;s/.*/0000/;q;: L;s/.*\(....\)$/\1/'`
|
micro_version=`echo $VERSION | sed -e 's/^[0-9]*\.[0-9]*\.\([0-9]*\).*/0000\1/' -e 't L' -e 's/.*/0000/;q' -e ': L' -e 's/.*\(....\)$/\1/'`
|
||||||
letter_version=`echo $VERSION | sed 's/^.*[0-9]\([^0-9]*\)$/\1/'`
|
letter_version=`echo $VERSION | sed 's/^.*[0-9]\([^0-9]*\)$/\1/'`
|
||||||
combined_version="$major_version.$minor_version.$micro_version$letter_version"
|
combined_version="$major_version.$minor_version.$micro_version$letter_version"
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue