From 3bb91bdd943edcd3b942607f7f7a9b863b09e1e8 Mon Sep 17 00:00:00 2001 From: "jean.chalard" Date: Fri, 5 Feb 2010 12:48:12 +0000 Subject: [PATCH] J : * 30sec tool to spot unsupported characters --- projects/mtg/bin/Res/lang/spot.rb | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 projects/mtg/bin/Res/lang/spot.rb diff --git a/projects/mtg/bin/Res/lang/spot.rb b/projects/mtg/bin/Res/lang/spot.rb new file mode 100644 index 000000000..15d979739 --- /dev/null +++ b/projects/mtg/bin/Res/lang/spot.rb @@ -0,0 +1,11 @@ +#!/usr/bin/ruby -w + +require 'iconv' +c = Iconv.new('UTF-8', 'WINDOWS-1252') +line = 0 +while l = gets + line += 1 + if l.match(/[\x80-\xFF]/) + puts line.to_s + " : " + c.iconv(l.gsub(/([\x80-\xFF])/, '\\1')) + end +end