home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #1 / NN_1993_1.iso / spool / comp / unix / shell / 5307 < prev    next >
Encoding:
Text File  |  1993-01-07  |  1.1 KB  |  37 lines

  1. Newsgroups: comp.unix.shell
  2. Path: sparky!uunet!stanford.edu!casbs!casbs.Stanford.EDU!patrick
  3. From: patrick@casbs.Stanford.EDU (Patrick Goebel)
  4. Subject: switch/case question under csh
  5. Message-ID: <PATRICK.93Jan7155500@casbs.Stanford.EDU>
  6. Sender: news@casbs.Stanford.EDU (CASBS News Service)
  7. Organization: Center for Advanced Study in the Behavioral Sciences
  8. Distribution: comp
  9. Date: Thu, 7 Jan 1993 23:55:00 GMT
  10. Lines: 25
  11.  
  12. In a switch statement under csh, I need a case that traps the [
  13. character (among others).  However, all the case statements I have
  14. tried yield a "Missing ]" error.  Here's what I've tried so far:
  15.  
  16. case "[":
  17. case "\[":
  18. case \[:
  19. case "[[]":
  20. case "[\[]":
  21. case "'['":
  22. case '[':
  23.  
  24. Does anyone know the magic incantation that quotes the [?  I need to
  25. do the same thing with some other "trouble" characters like * and _
  26. (underscore).
  27.  
  28. Thanks in advance for any pointers.
  29.  
  30. Cheers,
  31. patrick
  32. --
  33. Patrick Goebel                    E-MAIL: patrick@casbs.Stanford.EDU
  34. Network Administrator             VOICE:  (415) 321-2052
  35. CASBS, 202 Junipero Serra Blvd.   FAX:    (415) 321-1192
  36. Stanford, CA 94305                BEEPER: Temporarily Out of Order...
  37.