diff options
Diffstat (limited to 'src/gen_deftwmrc.sh')
-rwxr-xr-x | src/gen_deftwmrc.sh | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/gen_deftwmrc.sh b/src/gen_deftwmrc.sh new file mode 100755 index 0000000..ec7188c --- /dev/null +++ b/src/gen_deftwmrc.sh @@ -0,0 +1,17 @@ +#!/bin/sh + +rm -f ${1} +echo '/* ' >>${1} +echo ' * This file is generated automatically from the default' >>${1} +echo ' * twm bindings file system.twmrc by the twm Makefile.' >>${1} +echo ' */' >>${1} +echo '' >>${1} +echo 'const unsigned char *defTwmrc[] = {' >>${1} +sed \ + -e '/^#/d' \ + -e 's/"/\\"/g' \ + -e 's/^/ (const unsigned char *) "/' \ + -e 's/$/",/' \ + <${2} \ + >>${1} +echo ' (const unsigned char *) 0 };' >>${1} |