From: Ian Jackson Date: Sun, 10 May 2020 21:48:17 +0000 (+0100) Subject: nailing-cargo: message and debug improvements X-Git-Tag: nailing-cargo/1.0.0~214 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=21e65d18b7eb0084831d63b8aaa25663c3dbd618;p=nailing-cargo.git nailing-cargo: message and debug improvements Signed-off-by: Ian Jackson --- diff --git a/nailing-cargo b/nailing-cargo index 0997cdc..327b252 100755 --- a/nailing-cargo +++ b/nailing-cargo @@ -372,11 +372,14 @@ END } @ARGV; @command = @_, "set -${xe}; $pre $quoted; $post"; }; + print STDERR "$self: out-of-tree, building in: \`$build_absdir'\n" + if $verbose; if ($use eq 'really') { my $user = $getuser->(); my @pw = getpwnam $user or die "$self: oot.user \`$user' lookup failed\n"; my $homedir = $pw[7]; $sh_ec->('really','-u',$user,'env',"HOME=$homedir"); + print STDERR "$self: using really to run as user \`$user'\n" if $verbose; } elsif ($use eq 'ssh') { my $user = $getuser->(); $user .= '@localhost' unless $user =~ m/\@/; @@ -508,7 +511,14 @@ calculate_oot(); if ($dump) { eval ' use Data::Dumper; - print STDERR Dumper(\%manifests, \%packagemap, \@ARGV); + print STDERR Dumper(\%manifests) if $dump>=2; + print STDERR Dumper(\%packagemap, \@ARGV, + { src_absdir => $src_absdir, + worksphere => $worksphere, + subdir => $subdir, + oot_dir => $oot_dir, + oot_absdir => $oot_absdir, + build_absdir => $build_absdir }); ' or die $@; } @@ -518,10 +528,11 @@ $want_uninstall = 1; makebackups(); install(); -printf STDERR "$self: Nailed (%s manifests, %s packages)\n", +printf STDERR "$self: nailed (%s manifests, %s packages)\n", (scalar keys %manifests), (scalar keys %packagemap) if $verbose; +print STDERR "$self: invoking: @display_cmd\n" if $verbose; my $estatus = invoke(); uninstall();