Hi,
below is extract of my file
$cat outgoing-xfer|grep destination-path
--destination-path= \
What I need is to replace "--destination-path=" with "--destination-path=/home/dest"
i.e. desired output is
----destination-path=/home/dest \
I could achieve it with below command
$cat outgoing-xfer|grep destination-path|perl -pi -e "s/destination-path=/destination-path=\/home\/dest/g"
But the problem is that in this case i just wanted to append "/home/dest" for which I could easily escape "/" with just two "\", but I wonder if i have a long path like "/a/b/c/d/e/f/g/h/i/j" I will have to escape so many /. Is there any other way by which I can avoid escaping forward slash.
I tried following:
$cat outgoing-xfer|grep destination-path|perl -pi -e "s/destination-path=/'destination-path=\/home\/dest'/g"
but receiving follo error
Bareword found where operator expected at -e line 1, near "s/destination-path=/'destination-path=/home"
syntax error at -e line 1, near "s/destination-path=/'destination-path=/home"
Bad name after dest' at -e line 1.
tried with enclosing in double quotes as well but in vain