summaryrefslogtreecommitdiffstats
path: root/funtools/inc.sed
blob: b550331c9eb38c0da04a3cc862d8ee9bd79c83d0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
:
NAME="$1"
sed '
1i\
static char *XXXX="\\n

s/"/\\"/g
s/\\n/\\\\n/g
s/$/\\n/
$a\
\"
' | sed "s/XXXX/$NAME/" | awk '{printf("%s", $0)};END{printf(";\n")}'