#!/opt/perl/bin/perl -w # # ISO-8859-1 to legacy character set input filter for screen # use strict; $| = 1; scalar(@ARGV) or die "usage: i2lif charset\n"; my $charset = $ARGV[0]; system("stty raw >/dev/null 2>&1"); binmode STDIN, ":encoding(iso-8859-1)"; binmode STDOUT, ":encoding($charset)"; my $c; print $c while read(STDIN, $c, 1); .