Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery

Re^3: replace a line when regex match...

by revdiablo (Prior)
on Apr 12, 2005 at 05:25 UTC ( #446852=note: print w/replies, xml ) Need Help??

in reply to Re^2: replace a line when regex match...
in thread replace a line when regex match...

does some one have a better idea of loging into a remote box and running an inline script on it?

Inlining like this can be a real pain. In your case, the interpolation phase is clobbering all your variables before you even pass the code to $ssh->cmd. You should probably be using single quotes. I think it would be a lot easier to avoid the inlining altogether, though, and just save the script to a file on the remote host.

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://446852]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (5)
As of 2023-06-06 12:52 GMT
Find Nodes?
    Voting Booth?
    How often do you go to conferences?

    Results (26 votes). Check out past polls.