changeset 4729:417963e20c08

<oerjan> chmod +x ircslashes.pl; mv ircslashes.pl bin/slashes
author HackBot
date Sun, 24 Aug 2014 23:07:35 +0000
parents 3339ace022d7
children 93cde931c49a
files bin/slashes ircslashes.pl
diffstat 2 files changed, 23 insertions(+), 23 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/bin/slashes	Sun Aug 24 23:07:35 2014 +0000
@@ -0,0 +1,23 @@
+#!/usr/bin/perl -w
+#By Ørjan Johansen, 2009-2012.  This file is in the public domain.
+
+$| = 1;
+my $l = 0;
+
+$_ = join '', <>;
+while ($l < 512) {
+        if (s!^([^/\\]+)!! or s!^\\(.)!!s) { 
+                $l += length($1);
+                print($1);
+        }
+        else {
+            if (s!^/((?:[^/\\]|\\.)*)/((?:[^/\\]|\\.)*)/!!s) {
+                my ($s,$d) = ($1,$2);
+                $s =~ s/\\(.)/$1/gs;
+                $d =~ s/\\(.)/$1/gs;
+                while (s/(?:\Q$s\E)/$d/) { 
+                }
+            }
+            else { last; }
+        }
+}
--- a/ircslashes.pl	Sun Aug 24 23:07:01 2014 +0000
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,23 +0,0 @@
-#!/usr/bin/perl -w
-#By Ørjan Johansen, 2009-2012.  This file is in the public domain.
-
-$| = 1;
-my $l = 0;
-
-$_ = join '', <>;
-while ($l < 512) {
-        if (s!^([^/\\]+)!! or s!^\\(.)!!s) { 
-                $l += length($1);
-                print($1);
-        }
-        else {
-            if (s!^/((?:[^/\\]|\\.)*)/((?:[^/\\]|\\.)*)/!!s) {
-                my ($s,$d) = ($1,$2);
-                $s =~ s/\\(.)/$1/gs;
-                $d =~ s/\\(.)/$1/gs;
-                while (s/(?:\Q$s\E)/$d/) { 
-                }
-            }
-            else { last; }
-        }
-}