home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / unix / question / 11011 < prev    next >
Encoding:
Internet Message Format  |  1992-09-13  |  1.4 KB

  1. Path: sparky!uunet!ogicse!das-news.harvard.edu!husc-news.harvard.edu!husc3!huang2
  2. From: huang2@husc8.harvard.edu (Howard Huang)
  3. Newsgroups: comp.unix.questions
  4. Subject: Re: sh, tcsh, and alias differences
  5. Message-ID: <HUANG2.92Sep13093818@husc8.harvard.edu>
  6. Date: 13 Sep 92 16:38:18 GMT
  7. Article-I.D.: husc8.HUANG2.92Sep13093818
  8. References: <5313@blue.cis.pitt.edu.UUCP>
  9. Organization: Harvard Arts and Sciences Computer Services, Cambridge, MA
  10. Lines: 22
  11. Nntp-Posting-Host: husc8.harvard.edu
  12. In-reply-to: djbpitt+@pitt.edu's message of 30 Aug 92 19:35:25 GMT
  13.  
  14. djbpitt+@pitt.edu (David J Birnbaum) writes:
  15.  
  16.        "( expunge -r -i -l -s -y -m -v \* > /dev/tty ) > & /dev/null"
  17.  
  18.    but when I try it as a shell script I get a "not found" message. I've
  19.    tried different types of quotes and escapes - to no avail. Some varia-
  20.    tions object to the ampersand; others to /dev/null. Yes, the script is
  21.    executable, yes, it's in my path, yes, I removed the original purge from
  22.    my bin, and yes, I rehashed.
  23.  
  24. If you get a bad number error from /dev/null, it's because Bourne
  25. shell is attempting to execute your csh program.  To be safe add the
  26. line #!/bin/csh as the first line of your script.
  27.  
  28. You probably get "not found" because you're escaping the asterisk.
  29. Your program is actually trying to remove a file named '*'.  To make
  30. the asterisk act as a wildcard, remove the backslash.
  31.  
  32. Hope I caught your problem.
  33. --
  34. Howard C. Huang
  35. hhuang@teton.mitre.org
  36.