From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753282AbcJCWDD (ORCPT ); Mon, 3 Oct 2016 18:03:03 -0400 Received: from bombadil.infradead.org ([198.137.202.9]:55834 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750949AbcJCWCz (ORCPT ); Mon, 3 Oct 2016 18:02:55 -0400 Date: Mon, 3 Oct 2016 15:02:53 -0700 From: Darren Hart To: SeongJae Park Cc: shuah@kernel.org, dvhart@linux.intel.com, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] selftests/futex: Check ANSI terminal color support Message-ID: <20161003220253.GA3071@f23x64.localdomain> References: <20161002020218.19622-1-sj38.park@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20161002020218.19622-1-sj38.park@gmail.com> User-Agent: Mutt/1.7.0 (2016-08-17) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, Oct 02, 2016 at 11:02:18AM +0900, SeongJae Park wrote: > Because test for color support of the running shell does not aware ANSI > type terminals, it does not print colorful messages on some environemnt. > This commit modifies the test to aware ANSI type terminal, too. > > Signed-off-by: SeongJae Park No objection. Terminfo slists these separately, and I don't see a way to handle ANSI in a single command. Acked-by: Darren Hart > --- > tools/testing/selftests/futex/functional/run.sh | 2 +- > tools/testing/selftests/futex/run.sh | 2 +- > 2 files changed, 2 insertions(+), 2 deletions(-) > > diff --git a/tools/testing/selftests/futex/functional/run.sh b/tools/testing/selftests/futex/functional/run.sh > index e87dbe2a0b0d..7ff002eed624 100755 > --- a/tools/testing/selftests/futex/functional/run.sh > +++ b/tools/testing/selftests/futex/functional/run.sh > @@ -24,7 +24,7 @@ > > # Test for a color capable console > if [ -z "$USE_COLOR" ]; then > - tput setf 7 > + tput setf 7 || tput setaf 7 > if [ $? -eq 0 ]; then > USE_COLOR=1 > tput sgr0 > diff --git a/tools/testing/selftests/futex/run.sh b/tools/testing/selftests/futex/run.sh > index 4126312ad64e..88bcb1767362 100755 > --- a/tools/testing/selftests/futex/run.sh > +++ b/tools/testing/selftests/futex/run.sh > @@ -23,7 +23,7 @@ > > # Test for a color capable shell and pass the result to the subdir scripts > USE_COLOR=0 > -tput setf 7 > +tput setf 7 || tput setaf 7 > if [ $? -eq 0 ]; then > USE_COLOR=1 > tput sgr0 > -- > 2.10.0 > > -- Darren Hart Intel Open Source Technology Center