summaryrefslogtreecommitdiffstats
path: root/gnu/usr.bin/perl/eg/nih
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/usr.bin/perl/eg/nih')
-rw-r--r--gnu/usr.bin/perl/eg/nih10
1 files changed, 10 insertions, 0 deletions
diff --git a/gnu/usr.bin/perl/eg/nih b/gnu/usr.bin/perl/eg/nih
new file mode 100644
index 0000000..a376142
--- /dev/null
+++ b/gnu/usr.bin/perl/eg/nih
@@ -0,0 +1,10 @@
+eval "exec /usr/bin/perl -Spi.bak $0 $*"
+ if $running_under_some_shell;
+
+# $Header: /home/cvs/386BSD/ports/lang/perl/eg/nih,v 1.1.1.1 1993/08/23 21:29:43 nate Exp $
+
+# This script makes #! scripts directly executable on machines that don't
+# support #!. It edits in place any scripts mentioned on the command line.
+
+s|^#!(.*)|#!$1\neval "exec $1 -S \$0 \$*"\n\tif \$running_under_some_shell;|
+ if $. == 1;
OpenPOWER on IntegriCloud