source:
vendor/perl/5.8.8/perlsh@
3560
      
      | Last change on this file since 3560 was 3181, checked in by , 19 years ago | |
|---|---|
| File size: 396 bytes | |
| Line | |
|---|---|
| 1 | #!/usr/bin/perl | 
| 2 | |
| 3 | # Poor man's perl shell. | 
| 4 | |
| 5 | # Simply type two carriage returns every time you want to evaluate. | 
| 6 | # Note that it must be a complete perl statement--don't type double | 
| 7 | # carriage return in the middle of a loop. | 
| 8 | |
| 9 | $/ = "\n\n"; # set paragraph mode | 
| 10 | $SHlinesep = "\n"; | 
| 11 | while (defined($SHcmd = <>)) { | 
| 12 | $/ = $SHlinesep; | 
| 13 | eval $SHcmd; print $@ || "\n"; | 
| 14 | $SHlinesep = $/; $/ = ''; | 
| 15 | } | 
  Note:
 See   TracBrowser
 for help on using the repository browser.
    
