From 89a45afe87999d3772e60dcd13b4895fe5e50d59 Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Mon, 26 Mar 2012 18:20:55 +0000 Subject: better error messages when running as root or w/o sudo (no line numbers in output) --- iurt2 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'iurt2') diff --git a/iurt2 b/iurt2 index bc86925..26e1bcd 100755 --- a/iurt2 +++ b/iurt2 @@ -670,14 +670,14 @@ if ($run{use_cache}) { $run{daydate} = $daydate; plog('DEBUG', "using $run{run} as chroot extension"); $run{user} ||= $ENV{USER}; -die "Iurt should not be executed as root." if $run{user} eq "root"; +die "Iurt should not be executed as root.\n" if $run{user} eq "root"; $run{uid} = getpwnam $run{user}; plog('DEBUG', "using local user $run{user}, id $run{uid}"); my $luser = $run{user} || 'builder'; check_sudo_access() - or die "FATAL: you need to have sudo access on $config->{iurt_root_command} to run $program_name"; + or die "FATAL: you need to have sudo access on $config->{iurt_root_command} to run $program_name\n"; my $debug_tag = $run{debug} && '_debug'; $run{debug_tag} = $debug_tag; -- cgit v1.2.1