From: Nicolas Boisselier Date: Wed, 25 May 2016 11:35:38 +0000 (+0100) Subject: fix ssh bug X-Git-Url: https://git.nbdom.net/?a=commitdiff_plain;h=3d5e32b03c045f738202e6ed5e8781c1e552226a;p=nb.git fix ssh bug --- diff --git a/bin/dbq b/bin/dbq index 41bda7ab..6078e1fd 100755 --- a/bin/dbq +++ b/bin/dbq @@ -107,9 +107,7 @@ $url =~ s,^(\w+://)?([^@]+)@(.*?)$,$1$3, and push(@EXEC,"db=$2"); $url =~ m@^ssh://(.*)$@ and $Opt{ssh} = $1; #die "$url | ",join(' ',@EXEC); -exec('ssh',$Opt{ssh},'/usr/bin/env',"PATH=$ENV{PATH}","PERL5LIB=$ENV{PERL5LIB}",$NAME,map{s/"/\\"/g;'"'.$_.'"'} @EXEC) if $Opt{ssh}; -#exec('ssh',$Opt{ssh},$NAME,map{s/"/\\"/g;'"'.$_.'"'} @EXEC) if $Opt{ssh}; -#exec('ssh',$Opt{ssh},File::Spec->rel2abs($0),map{s/"/\\"/g;'"'.$_.'"'} @EXEC) if $Opt{ssh}; +exec('ssh',$Opt{ssh},'/usr/bin/env',"PATH=$ENV{PATH}","PERL5LIB=$ENV{PERL5LIB}",$NAME,map{s/"/\\"/g;'"'.$_.'"'} grep {$_ !~ /^(-+ssh|$Opt{ssh})/} @EXEC) if $Opt{ssh}; # # Add options to ARGV