home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / unix / question / 9588 < prev    next >
Encoding:
Internet Message Format  |  1992-07-30  |  820 b 

  1. Path: sparky!uunet!cis.ohio-state.edu!ucbvax!decwrl!parc!vine.cp10.es.xerox.com!hamilton
  2. From: hamilton@vine.cp10.es.xerox.com (Bruce A. Hamilton)
  3. Newsgroups: comp.unix.questions
  4. Subject: sh vs. filename extensions
  5. Summary: how test filename extensions using sh?
  6. Keywords: sh filename extensions
  7. Message-ID: <1992Jul29.225649.5471@vine.cp10.es.xerox.com>
  8. Date: 29 Jul 92 22:56:49 GMT
  9. Sender: BHamilton.LAX1B@Xerox.com
  10. Reply-To: BHamilton.LAX1B@Xerox.com
  11. Organization: Xerox Corp., El Segundo, CA, USA
  12. Lines: 14
  13.  
  14. Is there any way to test filename extensions using sh?  Using csh,
  15. I can simply say
  16.  
  17.     if ($f:e == "Z") then...
  18.  
  19. to test for a .Z file.  I can't find anything about substring matching
  20. in Kochan and Wood "Unix Shell Programming" (except under ksh).
  21.  
  22. Thanks,
  23.  
  24. -- 
  25. --Bruce
  26. BHamilton.LAX1B@Xerox.COM
  27. 310/333-3538
  28.