Liste des Groupes | Revenir à cu shell |
On 15.04.2024 14:22, James Harris wrote:>
I read up on getopts
It's the right tool.
but from tests it seems to require that switches
precede arguments rather than allowing them to be specified after, so
that doesn't seem very good, either.
That's the usual convention, first come the options (with optional
arguments), then the non-option arguments. Here's a syntax example
yagol [-s] [-w width] [-h height] [-g[ngen]] [-d density]
[-i infile] [-o outfile] [-r random-seed] [-u rule]
[-k|-t[sec]|-l|-f] [-p|-n|-c] [-a[gen]] [-m[rate]]
Les messages affichés proviennent d'usenet.