From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1RdyFr-0003aF-56 for garchives@archives.gentoo.org; Fri, 23 Dec 2011 06:05:19 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id E10FE21C0FC; Fri, 23 Dec 2011 06:05:09 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id AD68C21C0FC for ; Fri, 23 Dec 2011 06:05:09 +0000 (UTC) Received: from pelican.gentoo.org (unknown [66.219.59.40]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 1E2A21B402E for ; Fri, 23 Dec 2011 06:05:09 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by pelican.gentoo.org (Postfix) with ESMTP id 4B5E480042 for ; Fri, 23 Dec 2011 06:05:08 +0000 (UTC) From: "Brian Dolbec" To: gentoo-commits@lists.gentoo.org Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Brian Dolbec" Message-ID: <96236b49a1da4bd32ac64ba97ab828e0a7b5e9e8.dol-sen@gentoo> Subject: [gentoo-commits] proj/gentoolkit:gentoolkit commit in: pym/gentoolkit/ X-VCS-Repository: proj/gentoolkit X-VCS-Files: pym/gentoolkit/base.py X-VCS-Directories: pym/gentoolkit/ X-VCS-Committer: dol-sen X-VCS-Committer-Name: Brian Dolbec X-VCS-Revision: 96236b49a1da4bd32ac64ba97ab828e0a7b5e9e8 Date: Fri, 23 Dec 2011 06:05:08 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: quoted-printable X-Archives-Salt: 0b4860bb-e5cc-44d5-aa62-6c65f36c9e28 X-Archives-Hash: 2ea0d37446d17507e56ab42ad3df8007 commit: 96236b49a1da4bd32ac64ba97ab828e0a7b5e9e8 Author: Brian Dolbec gentoo org> AuthorDate: Fri Dec 23 06:01:45 2011 +0000 Commit: Brian Dolbec gmail com> CommitDate: Fri Dec 23 06:03:21 2011 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=3Dproj/gentoolkit.gi= t;a=3Dcommit;h=3D96236b49 Fix the term_width setting for the recent portage change, which is now re= turning 0 instead of -1. This should work for all portage versions. --- pym/gentoolkit/base.py | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/pym/gentoolkit/base.py b/pym/gentoolkit/base.py index 832d902..3d662d5 100644 --- a/pym/gentoolkit/base.py +++ b/pym/gentoolkit/base.py @@ -40,7 +40,7 @@ def initialize_configuration(): =20 # Get terminal size term_width =3D pp.output.get_term_size()[1] - if term_width =3D=3D -1: + if term_width < 1: # get_term_size() failed. Set a sane default width: term_width =3D 80 # Terminal size, minus a 1-char margin for text wrapping