Mike Bianchi <[email protected]> wrote:
|Peter,
|
|Thanks for looking into this.
|The fundamental problem is I attempt to process both -a A \
| and -aA without
|using getopts .
|
| Is getopts universal across sh/ksh/bash/zsh ?
It is part of POSIX since Issue 4, July 1992. I wouldn't care...
But to be truly portable in this mess all around us it may be useful
to do something like this (just did this three days ago for
mdocmx.sh and its compatibility with old Bourne shells etc.):
( echo "${0##*/}" ) >/dev/null 2>&1 && eval 'p="${0##*/}"' || p="${0}"
A very valuable source of shell history is provided by
Sven Mascheck [1], i can only recommend it highly.
'Took a quick look regarding getopts, if you don't use $OPTIND you
may be backward compatible to the eighties, shall this be your
desire.
[1] www.in-ulm.de/~mascheck
|If so, then I can repair this easily.
--steffen
_______________________________________________
bug-groff mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/bug-groff