]> git.nbdom.net Git - nb.git/commitdiff
/opt/nb/etc/profile.d/pdsh.sh
authorNicolas Boisselier <nicolas.boisselier@gmail.com>
Thu, 11 Jul 2019 22:46:41 +0000 (23:46 +0100)
committerNicolas Boisselier <nicolas.boisselier@gmail.com>
Thu, 11 Jul 2019 22:46:41 +0000 (23:46 +0100)
bin/csv2human
etc/profile.d/pdsh.sh

index fedf4d100f22734644fb03b2897ea41889c2d336..b708251ea7263e26bc0b3791c9270ad38c5293f3 100755 (executable)
@@ -62,7 +62,8 @@ while (<>) {
 
 exit unless @lines;
 
-my $tot = @lines - ($Opt{header} ? 0 : 1);
+# NB 11.07.19 Bug Wrong ! my $tot = @lines - ($Opt{header} ? 0 : 1);
+my $tot = @lines - ($Opt{header} ? 1 : 0);
 
 my $t = -1;
 my $format = "| ".join(" | ",map {$t+=$_+3; "\%-".$_."s"} @len)." |".chr(10);
index e30b195bd21e5a8d57c83df89f9b5a555ea2e255..2f58735546e434525c03544582cd7f8e952c491d 100644 (file)
@@ -8,7 +8,7 @@ export PDSH_SSH_ARGS="-q"
 
 [ "$SHELL" = "/bin/bash" ] || return 0
 pdsh_quiet() {
-       exec 3> >(grep -Ev '^(pdsh@|[^ :]+: (stdio forwarding failed|channel [0-9]+: open failed))')
+       exec 3> >(grep -Ev '^(pdsh@|([^ :]+: )?(stdio forwarding failed|channel [0-9]+: open failed))')
        pdsh $@ 2>&3
        exec 3>&-
 }