Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/5/84; site mcc-db.UUCP Path: utzoo!decvax!genrad!panda!talcott!harvard!seismo!ut-sally!mcc-db!jbc From: jbc@mcc-db.UUCP (John B. Chambers) Newsgroups: mod.std.unix Subject: Re: command line arguments Message-ID: <244@mcc-db.UUCP> Date: Sun, 14-Jul-85 19:56:19 EDT Article-I.D.: mcc-db.244 Posted: Sun Jul 14 19:56:19 1985 Date-Received: Mon, 15-Jul-85 10:04:10 EDT References: <2210@ut-sally.UUCP> Reply-To: std-unix-request@ut-sally Organization: MCC (Austin, TX) Lines: 35 Approved: jbc@mcc-db.UUCP From: John Chambers (guest moderator)Topic: getopts (command line arguments) continued ---------------------------------------------------------------------- Date: Mon, 8 Jul 85 14:41:54 PDT From: UCLA Computer Club Subject: Re: command line arguments Regarding getopts and the 'all arguments are proceded by a "-"': What about arguments that can be on/off switches, or can be positive or negative numbers? In other words, what is wrong with allowing '+' as an indicator of arguments? There are some commands that use it already. Incidently, what happens with getopts if the command line was command -n -30 and: Option n is fetched option 3 is fetched option 0 is fetched (No well written program would do all this, but essentially, what happens if an argument looks like a flag? Or have you never grep'ed for a string beginning with -?) ---------------------------------------------------------------------- -- John B. Chambers, Microelectronics and Computer Technology Corp., Austin, TX {ihnp4,seismo,ctvax}!ut-sally!mcc-db!jbc, jbc@ut-sally.ARPA, chambers@mcc.ARPA