Return to mkdict.sh CVS log | Up to [cvsweb.bsd.lv] / texi2mdoc / afl |
File: [cvsweb.bsd.lv] / texi2mdoc / afl / mkdict.sh (download)
Revision 1.3, Sat Feb 28 00:03:21 2015 UTC (9 years, 3 months ago) by kristaps
Prevent infinite macro expansion by incrementing a "depth" of recursive expansion IFF we're currently in a macro expansion already, where the start of the macro expansion begins at the macro name and NOT after the name has been parsed. |
#! /bin/sh rm -rf dict mkdir dict sed -n '/TEXICMD__BEGIN/,/TEXICMD__END/p' ../main.c | \ tail -n +2 | \ sed '$d' | \ awk '{print $3}' | \ sed -e 's!^\"!!' -e 's!\",$!!' | \ while read ln ; do [ ${#ln} -gt 1 ] && printf "$ln" >"dict/$ln" ; done