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/common | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'libs/common') diff --git a/libs/common b/libs/common index fd001a5d..750886db 100755 --- a/libs/common +++ b/libs/common @@ -157,7 +157,7 @@ file_checksum_check() { if ! [ -f "$checksum_path" ] then - printf '%s\n' 'Could not verify file checksum!' >&2 + printf 1>&2 '%s\n' 'Could not verify file checksum!' return 1 fi @@ -187,7 +187,7 @@ file_signature_check() { if ! [ -f "$signature_path" ] then - printf '%s\n' 'Could not verify file signature!' >&2 + printf 1>&2 '%s\n' 'Could not verify file signature!' return 1 fi @@ -383,7 +383,7 @@ requirements() { if [ -z "$requirement_path" ] then - printf '%s\n' "Missing requirement: $requirement" >&2 + printf 1>&2 '%s\n' "Missing requirement: $requirement" exit 1 fi done @@ -400,7 +400,7 @@ requirements_root() { if [ -z "$requirement_path" ] then - printf '%s\n' "Missing requirement: $requirement" >&2 + printf 1>&2 '%s\n' "Missing requirement: $requirement" exit 1 fi done @@ -429,8 +429,8 @@ execute_root() { local sudo=$( which sudo 2> /dev/null || true ) local arguments - printf '%s' 'Running command as root: ' >&2 - printf '%b\n' "$*" >&2 + printf 1>&2 '%s' 'Running command as root: ' + printf 1>&2 '%b\n' "$*" if ! [ -z "$sudo" ] then -- cgit v1.2.3-70-g09d2