X-Git-Url: https://diplodocus.org/git/nmh/blobdiff_plain/78160430e458e1accc5d2e0d2748af800cf8cd81..d807e761d3a99fc39d7999fed37074e865e888b5:/etc/bash_completion_nmh-gen diff --git a/etc/bash_completion_nmh-gen b/etc/bash_completion_nmh-gen index 7451b2af..5a97a914 100755 --- a/etc/bash_completion_nmh-gen +++ b/etc/bash_completion_nmh-gen @@ -9,8 +9,8 @@ mhchart=man/mh-chart.man #### Extract switches for nmh program. -switches() { - local program=$1 +prog_switches() { + program=$1 #### Extract lines from just after .B program-name to just before #### blank line, and then only those that start with .RB, e.g., @@ -51,7 +51,7 @@ EOF programs=`egrep '\.B [^\-]' "$mhchart" | \ sed -e 's/^\.B //' -e 's/ .*//' -e 's|%[^%]*%/||' -e 's/\\-/-/'` for program in $programs; do - switches=`switches "$program"` + switches=`prog_switches "$program"` # Support mime as alias for mhbuild. [ "$program" = mhbuild ] && program='mhbuild|mime' printf ' %s) switches=(%s) ;;\n' "$program" "$switches"