sed 's;/\* *---;/*---X_X;g' |
sed 's;\([} ]\)else[ ]*\(/\*.*\)$;\1else\
\2;g' | # workaround for indent bug
- detab -t4 -qc >/tmp/$$a
+ detab -t4 -qc |
+ sed 's;^DATA(.*$;/*&*/;' >/tmp/$$a # protect backslashes in DATA()
indent -bad -bap -bbb -bc -bl -d0 -cdb -nce -cli1 -di16 -nfc1 \
-lp -nip -nbc -psl -di1 -i4 -l75 -npro /tmp/$$a >/tmp/$$ 2>&1
if [ "$?" -ne 0 -o -s /tmp/$$ ]
cat /tmp/$$
fi
cat /tmp/$$a |
+ sed 's;^/\*\(DATA(.*\)\*/$;\1;' |
detab -t8 -qc |
entab -t4 -qc |
sed 's;/\*---X_X;/* ---;g' >/tmp/$$ && cat /tmp/$$ >$FILE
#
#
# IDENTIFICATION
-# $Header: /cvsroot/pgsql/src/backend/catalog/Attic/genbki.sh,v 1.7 1997/09/06 00:22:36 momjian Exp $
+# $Header: /cvsroot/pgsql/src/backend/catalog/Attic/genbki.sh,v 1.8 1997/09/06 18:27:11 momjian Exp $
#
# NOTES
# non-essential whitespace is removed from the generated file.
# ----------------
# also, change Oid to oid. -- AY 8/94.
# also, change NameData to name. -- jolly 8/21/95.
+# put multi-line start/end comments on a separate line
#
cat $SYSFILES | \
-sed -e 's/\/\*.*\*\///g' \
- -e 's/;[ ]*$//g' \
+sed -e 's;/\*.*\*/;;g' \
+ -e 's;/\*;\
+/*\
+;g' \
+ -e 's;\*/;\
+*/\
+;g' | # we must run a new sed here to see the newlines we added
+sed -e 's/;[ ]*$//g' \
-e 's/^[ ]*//' \
- -e 's/\[ ]Oid/\ oid/g' \
- -e 's/\[ ]NameData/\ name/g' \
+ -e 's/[ ]Oid/\ oid/g' \
+ -e 's/[ ]NameData/\ name/g' \
-e 's/^Oid/oid/g' \
-e 's/^NameData/\name/g' \
-e 's/(NameData/(name/g' \