quilt-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Quilt-dev] Term::ReadKey in test/run


From: John Vandenberg
Subject: Re: [Quilt-dev] Term::ReadKey in test/run
Date: Fri, 23 Sep 2005 19:18:32 +1000

Hi Jean,

On 9/6/05, Jean Delvare <address@hidden> wrote:
> I don't see what prevents us from still using $ENV{COLUMNS} where
> possible and default to 80 where not. This also acts as a quick
> replacement to the command line option you were suggesting, as the user
> can do:
>   COLUMNS=120 make some.test
>
> --- quilt.orig/test/run Thu Feb 10 11:59:24 2005
> +++ quilt/test/run      Tue Sep  6 11:50:53 2005
> @@ -13,7 +13,6 @@
>  use FileHandle;
>  use Getopt::Std;
>  use POSIX qw(isatty setuid);
> -use Term::ReadKey;
>  use vars qw($opt_l $opt_v);
>
>  no warnings qw(taint);
> @@ -33,7 +32,7 @@
>  my $prog_line;
>  my ($tests, $failed) = (0,0);
>  my $lineno;
> -my $width=((GetTerminalSize)[0] >> 1);
> +my $width=(($ENV{COLUMNS} || 80) >> 1);
>
>  for (;;) {
>    my $line = <>; $lineno++;

We appear to have forgotten about this one.  Your suggestion is simple
and effective; it has my vote.

--
John




reply via email to

[Prev in Thread] Current Thread [Next in Thread]