mirror of
https://git.postgresql.org/git/postgresql.git
synced 2024-10-03 11:26:49 +02:00
Handle tabs after closing brace in first column with less indenting.
This commit is contained in:
parent
158129be72
commit
d447dbf392
@ -1454,12 +1454,15 @@ do
|
|||||||
cat /tmp/$$
|
cat /tmp/$$
|
||||||
fi
|
fi
|
||||||
cat /tmp/$$a |
|
cat /tmp/$$a |
|
||||||
|
# remove tabs and retab with four spaces
|
||||||
|
detab -t8 -qc |
|
||||||
|
entab -t4 -qc |
|
||||||
sed 's;^/\*\(DATA(.*\)\*/$;\1;' |
|
sed 's;^/\*\(DATA(.*\)\*/$;\1;' |
|
||||||
sed 's;^/\*\(CATALOG(.*\)\*/$;\1;' |
|
sed 's;^/\*\(CATALOG(.*\)\*/$;\1;' |
|
||||||
sed 's;/\*---X_X;/* ---;g' |
|
sed 's;/\*---X_X;/* ---;g' |
|
||||||
# workaround indent bug
|
# workaround indent bug
|
||||||
sed 's;^static[ ][ ]*;static ;g' |
|
sed 's;^static[ ][ ]*;static ;g' |
|
||||||
sed 's;^}[ ][ ]*;} ;' |
|
sed 's;^} *;} ;' |
|
||||||
# pull in #endif comments
|
# pull in #endif comments
|
||||||
sed 's;^#endif[ ][ ]*/\*;#endif /*;' |
|
sed 's;^#endif[ ][ ]*/\*;#endif /*;' |
|
||||||
# work around #else indenting next line if #ifdef defines variables at top
|
# work around #else indenting next line if #ifdef defines variables at top
|
||||||
@ -1473,9 +1476,6 @@ do
|
|||||||
}
|
}
|
||||||
else print $0;
|
else print $0;
|
||||||
}' |
|
}' |
|
||||||
# remove tabs and retab with four spaces
|
|
||||||
detab -t8 -qc |
|
|
||||||
entab -t4 -qc |
|
|
||||||
# add space after comments that start on tab stops
|
# add space after comments that start on tab stops
|
||||||
sed 's;\([^ ]\)\(/\*.*\*/\)$;\1 \2;' |
|
sed 's;\([^ ]\)\(/\*.*\*/\)$;\1 \2;' |
|
||||||
# move trailing * in function return type
|
# move trailing * in function return type
|
||||||
|
Loading…
Reference in New Issue
Block a user