From 4e3505463eadffd9f1994f8ecaba9b1d693ec7bf Mon Sep 17 00:00:00 2001 From: Andrew Robbins Date: Wed, 25 Oct 2017 23:11:15 -0400 Subject: Modify fd copying in printf calls for readability --- libs/tool | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'libs/tool') diff --git a/libs/tool b/libs/tool index 8ed70e18..41bf0cc1 100755 --- a/libs/tool +++ b/libs/tool @@ -79,7 +79,7 @@ tool_action() { if ! tool_check "$tool" then - printf '%s\n' "Tool $tool check failed" >&2 + printf 1>&2 '%s\n' "Tool $tool check failed" return 1 fi @@ -97,7 +97,7 @@ tool_action() { return 0 fi - printf '%s\n' "Tool $tool $action (with ${arguments:-no argument})" >&2 + printf 1>&2 '%s\n' "Tool $tool $action (with ${arguments:-no argument})" ( set -e @@ -106,10 +106,10 @@ tool_action() { if [ $? -ne 0 ] then - printf '\n%s\n' "Tool $tool $action (with ${arguments:-no argument}) failed" >&2 + printf 1>&2 '\n%s\n' "Tool $tool $action (with ${arguments:-no argument}) failed" return 1 else - printf '\n%s\n' "Tool $tool $action (with ${arguments:-no argument}) completed" >&2 + printf 1>&2 '\n%s\n' "Tool $tool $action (with ${arguments:-no argument}) completed" fi ) } @@ -125,7 +125,7 @@ tool_action_check() { if ! tool_check "$tool" then - printf '%s\n' "Tool $tool check failed" >&2 + printf 1>&2 '%s\n' "Tool $tool check failed" return 1 fi @@ -162,7 +162,7 @@ tool_action_helper() { if ! tool_check "$tool" then - printf '%s\n' "Tool $tool check failed" >&2 + printf 1>&2 '%s\n' "Tool $tool check failed" return 1 fi -- cgit v1.2.3-70-g09d2