B
Bikas De simex
Hi,
I want to execute a remote bash script that take one string argument by
using system() or %x[]. But the value argument is not transmited
remotely.
Here my program
def trait_fic(repfic)
Find.find(repfic) do |path|
unless FileTest.directory?(path)
dirc="#{path}".split(/\//)
puts "#{dirc[3]}\n"
system('plink -pw ppp xxx@yyyy /tmp/essai.ksh #{dirc[3]}')
end
end
end
trait_fic('I:/toto')
I have got:
PTOTO -------------------------> This is done by puts "#{dirc[3]}\n"
<---
Le batch traité est
..........................
/tmp/mma/essai.ksh[36]: syntax error at line 214 : `"Nous traitons le
batch $BATH ...n"' unexpected
Is there any way to transmit remotely this value. I also try net/ssh
with no succes.
Thanks in Advance
I want to execute a remote bash script that take one string argument by
using system() or %x[]. But the value argument is not transmited
remotely.
Here my program
def trait_fic(repfic)
Find.find(repfic) do |path|
unless FileTest.directory?(path)
dirc="#{path}".split(/\//)
puts "#{dirc[3]}\n"
system('plink -pw ppp xxx@yyyy /tmp/essai.ksh #{dirc[3]}')
end
end
end
trait_fic('I:/toto')
I have got:
ruby essai0.rb
PTOTO -------------------------> This is done by puts "#{dirc[3]}\n"
<---
Le batch traité est
..........................
/tmp/mma/essai.ksh[36]: syntax error at line 214 : `"Nous traitons le
batch $BATH ...n"' unexpected
Is there any way to transmit remotely this value. I also try net/ssh
with no succes.
Thanks in Advance