From owner-freebsd-standards Tue Jul 23 11:42:57 2002 Delivered-To: freebsd-standards@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6124E37B400; Tue, 23 Jul 2002 11:42:55 -0700 (PDT) Received: from bremen.shuttle.de (bremen.shuttle.de [194.95.249.251]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4FF3543E42; Tue, 23 Jul 2002 11:42:54 -0700 (PDT) (envelope-from schweikh@schweikhardt.net) Received: from bremen.shuttle.de (localhost [127.0.0.1]) by bremen.shuttle.de (Postfix) with ESMTP id EE20E17D35; Tue, 23 Jul 2002 20:42:50 +0200 (CEST) Received: (from uucp@localhost) by bremen.shuttle.de (8.12.3/8.12.3/Debian -4) with UUCP id g6NIgoa9022279; Tue, 23 Jul 2002 20:42:50 +0200 Received: from hal9000.schweikhardt.net (localhost [127.0.0.1]) by hal9000.schweikhardt.net (8.12.5/8.12.5) with ESMTP id g6NIgPEu038766; Tue, 23 Jul 2002 20:42:25 +0200 (CEST) (envelope-from schweikh@hal9000.schweikhardt.net) Received: (from schweikh@localhost) by hal9000.schweikhardt.net (8.12.5/8.12.3/Submit) id g6NIgPA8038765; Tue, 23 Jul 2002 20:42:25 +0200 (CEST) Date: Tue, 23 Jul 2002 20:42:25 +0200 From: Jens Schweikhardt To: Johan Karlsson Cc: standards@freebsd.org Subject: Re: repeated options to mean different thing Message-ID: <20020723204225.A38605@schweikhardt.net> References: <20020723194802.C50574@numeri.campus.luth.se> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20020723194802.C50574@numeri.campus.luth.se> User-Agent: Mutt/1.3.22.1i Sender: owner-freebsd-standards@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Johan, On Tue, Jul 23, 2002 at 07:48:02PM +0200, Johan Karlsson wrote: # Hi # # In PR 40709 I suggested to use to use -v to mean # be verbose (current behaivour) and repeated -v # (e.g chmod -v -v 777 file, or chmod -vv 777 file) # to mean be very verbose. # # tcpdump uses a variant of this where -v mean be verbose # and -vv mean be even more verbose. # # Sheldon told me to ask here if this goes against POSIX # or some other standard. # # So, is the use of repeated options prohibited by POSIX? You can find the gory details in the POSIX Utility Syntax Guidelines, http://www.opengroup.org/onlinepubs/007904975/basedefs/xbd_chap12.html#tag_12_02 # Or is this a stupid idea from some other standards point of # view? I'd say multiple -v becomes clumsy once you have more than three levels of verbosity. Why not use -v level or even -v bitmask in cases where you don't have to be backwards compatible (i.e. if a utility has had -v as a single letter option it's a bad idea to turn it into an option taking a level arg. Breaks older scripts.) Regards, Jens -- Jens Schweikhardt http://www.schweikhardt.net/ SIGSIG -- signature too long (core dumped) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-standards" in the body of the message