2021-09-08 19:38:07 -04:00
|
|
|
#!/bin/bash
|
|
|
|
|
2022-06-08 16:03:44 -04:00
|
|
|
cd "$( dirname "${BASH_SOURCE[0]}" )"/../../../vscode || { echo "'vscode' dir not found"; exit 1; }
|
2021-09-08 19:38:07 -04:00
|
|
|
|
2021-10-11 20:05:59 -04:00
|
|
|
input=LICENSE.txt
|
|
|
|
target=LICENSE.rtf
|
2021-09-08 19:38:07 -04:00
|
|
|
|
2021-10-11 20:05:59 -04:00
|
|
|
cat - >$target <<_EOF
|
|
|
|
{\rtf1\ansi\deff0{\fonttbl{\f0\fnil\fcharset0 Consolas;}}
|
|
|
|
\viewkind4\uc1\pard\lang1033\f0\fs22
|
2021-09-08 19:38:07 -04:00
|
|
|
|
2021-10-11 20:05:59 -04:00
|
|
|
_EOF
|
2021-09-08 19:38:07 -04:00
|
|
|
|
2021-10-11 20:05:59 -04:00
|
|
|
sed -zE -e 's/([A-Za-z,])\r?\n([A-Za-z])/\1 \2/g' -e 's/\r?\n\r?\n/\\par\n\n/g' -e 's/(\\par\n)/\\line\1/g' -e 's/\s*(Copyright)/\\line\n\1/g' -e 's/(\\par)\\line/\1\n/g' $input >> $target
|
2021-09-08 19:38:07 -04:00
|
|
|
|
|
|
|
|
2021-10-11 20:05:59 -04:00
|
|
|
cat - >>$target <<_EOF
|
|
|
|
\par
|
|
|
|
}
|
|
|
|
_EOF
|