X-Git-Url: https://git.donarmstrong.com/?p=deb_pkgs%2Fscowl.git;a=blobdiff_plain;f=src%2Fadd-accents;fp=src%2Fadd-accents;h=16407318803451ad0c3f61bd70dd7b345463dcf5;hp=0000000000000000000000000000000000000000;hb=b13ea8a082364672c6de2b010e558211ff52ec9a;hpb=01534a94130c1f5a3a230cf4fe18365a235ba271 diff --git a/src/add-accents b/src/add-accents new file mode 100755 index 0000000..1640731 --- /dev/null +++ b/src/add-accents @@ -0,0 +1,30 @@ +#!/usr/bin/perl + +open A, "working/with-accents.lst"; +open B, "working/without-accents.lst"; + +for (;;) +{ + $with_accent = or last; + chop $with_accent; + $without_accent = or die; + chop $without_accent; + $lookup{$without_accent} = $with_accent; +} + +while () { + chop; + if (exists $lookup{$_}) { + print "$lookup{$_}\n"; + } else { + my $w = $_; + s/\'s$//; + if (exists $lookup{$_}) { + print "$lookup{$_}'s\n"; + } else { + print "$w\n"; + } + } +} + +