Link to home
Start Free TrialLog in
Avatar of deibel
deibelFlag for Germany

asked on

SED escape /

Hi experts,
I worked with the SED command and i want to replace a URL with the SED command in a configuration file.
In the configuration file i have this line:     /owa https://example.de/owa
And with the SED i want to replace this line so i used this command:

sed -e "s/owa https:.*/owa https://example2.de/owa/g" /etc/apache2/sites-available/test.conf

and i got this error message: sed: -e expression #1, char 27: unknown option to `s'

without the / the command works so how can i escape or use the / in the command?
ASKER CERTIFIED SOLUTION
Avatar of oBdA
oBdA

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of deibel

ASKER

Thank you both.

I used your solutions and it works.