home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / unix / shell / 4822 < prev    next >
Encoding:
Internet Message Format  |  1992-11-20  |  1.0 KB

  1. Path: sparky!uunet!olivea!gossip.pyramid.com!pyramid!infmx!hartman
  2. From: hartman@informix.com (Robert Hartman)
  3. Newsgroups: comp.unix.shell
  4. Subject: Re: Does C-shell have subroutine capability
  5. Message-ID: <1992Nov20.184756.9138@informix.com>
  6. Date: 20 Nov 92 18:47:56 GMT
  7. References: <1992Nov14.195151.15122@cbis.ece.drexel.edu> <1992Nov20.050115.13999@tellab5.tellabs.com>
  8. Sender: news@informix.com (Usenet News)
  9. Organization: Informix Software, Inc.
  10. Lines: 20
  11.  
  12. In article <1992Nov20.050115.13999@tellab5.tellabs.com> seong@tellabs.com (Scott Seong) writes:
  13. >-- 
  14. >With C-shell, writing a 'subroutine' is impossible. If you are running
  15. >Ultrix 4.2, go with ksh.  It's not that different from csh.
  16.  
  17. Well, it's not exactly "impossible," but it is a little wierd:
  18.  
  19.  
  20.     % alias foo 'source foo'
  21.     % cat > foo
  22.     echo I got sourced in!
  23.     ^D
  24.     % foo    
  25.     I got sourced in!
  26.  
  27. After using both shells, I like ksh a little better.  The only gripe
  28. I have with ksh is that I haven't been able to figure out how to
  29. list the definition of an individual shell function.  Any tips?
  30.  
  31. -r
  32.