Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site turtlevax.UUCP Path: utzoo!watmath!clyde!burl!ulysses!mhuxr!ihnp4!pesnta!amd!turtlevax!ken From: ken@turtlevax.UUCP (Ken Turkowski) Newsgroups: net.puzzle,net.unix Subject: How to get the C-shell to recognize -? Message-ID: <758@turtlevax.UUCP> Date: Fri, 10-May-85 12:47:10 EDT Article-I.D.: turtleva.758 Posted: Fri May 10 12:47:10 1985 Date-Received: Sat, 11-May-85 04:40:04 EDT Distribution: net Organization: CADLINC, Inc. @ Menlo Park, CA Lines: 35 Xref: watmath net.puzzle:832 net.unix:4477 In trying to make my shell scripts understand a standard help inquiry, I would like to have the csh recognize the flag "-?" , so that one might say: gobble -\? and have it echo: gobble takes the flags: -v Verbose -o Output is directed to rather than the default -? Prints this help message ... I have done this easily with sh, but csh is very stubborn. I have tried switch ("$flag") case case -?: case '-?': case -\?: case "-?": case "-\?": case "-\\?": case "-\\\?": case "-\\\\?": case "-\\\\\?": case '-?': case '-\?': case '-\\?': case '-\\\?': case '-\\\\?': case '-\\\\\?': endsw and none of them will match. So I offer this problem as a puzzle to the Unix community (including Bill Joy, the author). -- Ken Turkowski @ CADLINC, Menlo Park, CA UUCP: {amd,decwrl,hplabs,nsc,seismo,spar}!turtlevax!ken ARPA: turtlevax!ken@DECWRL.ARPA