Now does four additional things:

# trim leading white space
# trim trailing white space
# removing empty lines
# join a trailing [ with the next line
This commit is contained in:
alba 2002-07-11 21:43:00 +00:00
parent f0f81ac376
commit 68fe133eb5
1 changed files with 17 additions and 0 deletions

View File

@ -1,2 +1,19 @@
#!/bin/sed -f
# escape single unprotected quotes with a backslash
s#\([^\\']\)'\([^']\)#\1''\2#g
# trim leading white space
s#^[[:space:]]*##
# trim trailing white space
s#[[:space:]]*$##
# removing empty lines
/^$/d
# join a trailing [ with the next line
/\[$/ {
N
s#\[[[:space:]]*#[#
}