summaryrefslogtreecommitdiffabout
path: root/tools/enflesh_filters_list.sh
authorMichael Krelin <hacker@klever.net>2006-08-11 16:01:56 (UTC)
committer Michael Krelin <hacker@klever.net>2006-08-11 16:01:56 (UTC)
commit0c21a7a0d5b84dc6726462f0fbe51b8c32433262 (patch) (unidiff)
tree9df6334cb1a61efebe68f7bcef9aa119a823626a /tools/enflesh_filters_list.sh
parent9bcc235e575a95989a5903394c127accbeef2e0f (diff)
downloadmidillo-0c21a7a0d5b84dc6726462f0fbe51b8c32433262.zip
midillo-0c21a7a0d5b84dc6726462f0fbe51b8c32433262.tar.gz
midillo-0c21a7a0d5b84dc6726462f0fbe51b8c32433262.tar.bz2
initial commit into repository0.0
Diffstat (limited to 'tools/enflesh_filters_list.sh') (more/less context) (ignore whitespace changes)
-rw-r--r--tools/enflesh_filters_list.sh20
1 files changed, 20 insertions, 0 deletions
diff --git a/tools/enflesh_filters_list.sh b/tools/enflesh_filters_list.sh
new file mode 100644
index 0000000..f1d8dfc
--- a/dev/null
+++ b/tools/enflesh_filters_list.sh
@@ -0,0 +1,20 @@
1#!/bin/sh
2srcfile="${1}"
3enumfile="${2}"
4deffile="${3}"
5IFS=':'
6exec 5>${enumfile}
7exec 6>${deffile}
8SEQN=0
9LN=0
10cat ${srcfile} \
11 | while read id ids help ; do
12 LN="`expr ${LN} + 1`"
13 test -z "${id}" && continue
14 test "${id}" != "${id# }" && continue
15 echo "#line ${LN} \"${srcfile}\"" >&5
16 echo " filter_${id} = ${SEQN}," >&5
17 echo "#line ${LN} \"${srcfile}\"" >&6
18 echo ' { { "'$(echo $ids|sed -e 's-/-", "-g')'", 0 }, "'"${help}"'", false },' >&6
19 SEQN="`expr ${SEQN} + 1`"
20 done