From 4f9541f1f5e193e252a890062cd01970f2204619 Mon Sep 17 00:00:00 2001 From: Tom Ryder Date: Thu, 18 Aug 2016 14:35:16 +1200 Subject: Suppress stderr from command -v checks Now I remember--old Bash prints failure messages to stderr for this call. That'll be why I was suppressing both streams initially. --- sh/profile.d/pager.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sh/profile.d/pager.sh') diff --git a/sh/profile.d/pager.sh b/sh/profile.d/pager.sh index a74e6aa1..f0c4fab4 100644 --- a/sh/profile.d/pager.sh +++ b/sh/profile.d/pager.sh @@ -1,6 +1,6 @@ # If we don't have less(1), we'll just use whatever pager the application or # system deems fit -command -v less >/dev/null || return +command -v less >/dev/null 2>&1 || return # Use less(1) as my PAGER PAGER=less -- cgit v1.2.3