From db2c5da7a0fc88f9097e3d67541f275fd679daa3 Mon Sep 17 00:00:00 2001 From: Karl Blomster Date: Fri, 26 Dec 2008 23:36:39 +0000 Subject: [PATCH] add oneliner version of unicodereplace.pl to the script itself so I don't forget about it Originally committed to SVN as r2524. --- traydict/unicodereplace.pl | 2 ++ 1 file changed, 2 insertions(+) diff --git a/traydict/unicodereplace.pl b/traydict/unicodereplace.pl index 9ffcbd602..6c18a6f93 100644 --- a/traydict/unicodereplace.pl +++ b/traydict/unicodereplace.pl @@ -5,6 +5,8 @@ #### # Usage: unicodereplace.pl infile outfile ############################# +# oneliner version: +# perl -C7 -ne'print map {$c=ord; ($c < 127 or $c == 0xFEFF or $c == 0xFFFE) ? $_ : sprintf "\\u%04x", $c} split //;' infile > outfile use warnings; use strict;