Files
PolyORB/support/gensedfile
Thomas Quinot 0d1f2ae9f3 Merge GLADE documentation into PolyORB User's Guide.
For G703-022

Subversion-branch: /trunk/polyorb
Subversion-revision: 116819
2007-10-12 15:54:06 +00:00

29 lines
429 B
Bash
Executable File

#!/bin/sh
if [ $# != 2 ]; then
echo "Usage: $0 <keyword file> <keyword substitution file>"
exit 0
fi
SOURCE=$1
TARGET=$2
/bin/rm -f ${TARGET}
case ${SOURCE} in
*ada*)
cat <<EOF >>${TARGET}
/--/s/@/@@/g
/--/b
EOF
;;
*idl*)
cat <<EOF >>${TARGET}
s/{/\@{/g
s/}/\@}/g
EOF
;;
esac
for k in `cat ${SOURCE}`; do
cat <<EOF >>${TARGET}
s/\([^\{\}a-zA-Z0-9_]\)${k}/\1\@b\{${k}\}/g
s/^${k}/\@b\{${k}\}/g
EOF
done