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

  1. Path: sparky!uunet!elroy.jpl.nasa.gov!sdd.hp.com!hplabs!ucbvax!mtxinu!sybase!robert
  2. From: robert@sybase.com (Robert Garvey)
  3. Newsgroups: comp.unix.questions
  4. Subject: Re: What does \!* mean in csh history subst ?
  5. Message-ID: <23143@sybase.sybase.com>
  6. Date: 5 Sep 92 00:10:13 GMT
  7. References: <1992Sep2.173037.16135@eng.ufl.edu>
  8. Sender: news@Sybase.COM
  9. Distribution: usa
  10. Organization: Sybase
  11. Lines: 26
  12.  
  13. In article <1992Sep2.173037.16135@eng.ufl.edu>, zzang@whale.uucp (Zhuo Zang[~{j0WA~}]) writes:
  14. |> I am confused by the meaning of the
  15. |> csh history substitution \!* .
  16.  
  17. Ah, csh history is inherently confusing to many.
  18.  
  19. |> the man says it means: take word 1-$ from previou cmd. 
  20. |> my question is: if the previous cmd have pipes, like
  21. |> > cat foo.1 | lpr
  22. |> what is the 1-$ ? if you use:
  23. |> >more !*
  24. |> ?: 1-$ is foo.1 or foo.1 |lpr
  25.  
  26. You might want to have everything following a csh alias as parameters to
  27. the first command in a pipe, like:
  28.     alias mtoday 'from \!* | /usr/bin/fgrep "`date | colrm 11`"'
  29.  
  30. The words of a csh command shell include pipes, semicolons, and
  31. redirect symbols.  If you would want to more the file in your example
  32. command line, use:
  33.     more !:1
  34. -- 
  35. Robert Garvey robert@sybase.com {sun,lll-tis,pyramid,pacbell}!sybase!robert
  36.           Sybase, Inc   6475 Christie Ave   Emeryville, CA   94608-1010
  37.  
  38. If Sybase were to pay employees for their opinions, they couldn't afford me.
  39.