mutt stable branch with some hacks
at jcs 38 lines 635 B view raw
1#!/bin/sh 2 3# $Id$ 4 5echo '/* Automatically generated by gen_defs. Do not edit! */' 6echo '' 7 8for mode in help defs; do 9 case $mode in 10 help) 11 echo "#ifdef HELP_C" 12 echo "const char *HelpStrings[] = {" 13 expr='i\ 14 /* L10N: Help screen function description.\ 15 Generated from one of the OPS files. */ 16s;^[^ ]* *\(.*\); N_(\1),;' 17 ;; 18 *) 19 echo "enum {" 20 expr='s;^\([^ ]*\).*; \1,;' 21 ;; 22 esac 23 for i in $*; do 24 sed -e '/^\/\*/d' -e "$expr" < $i 25 done 26 if test $mode = help; then 27 echo ' NULL' 28 else 29 echo ' OP_MAX' 30 fi 31 echo "};" 32 if test $mode = help; then 33 echo "#endif /* MAIN_C */" 34 echo '' 35 fi 36done 37 38exit 0