Search Results

Search: Posts Made By: DaHai
2,454
Posted By DaHai
Thanks!
Thank you both for your help!

Here is what I created using both your suggestions:

sed -i -r "/10\.8\.0\.0/n; s/route +([0-9]{1,3}\.){3}[0-9]{1,3} +255\.255\.255\.0/route $RASPI_IP...
2,454
Posted By DaHai
Sorry about not using code tags, I've added them....
Sorry about not using code tags, I've added them. It wasn't really code, though. What I wrote was crap :(

Thanks for the reply and help!!!
2,454
Posted By DaHai
sed find/replace a pattern, but not this one..
I've got a file like so:

...lots of lines, etc.
push "route 10.8.0.0 255.255.255.0"
push "route 192.168.1.123 255.255.255.0"
...lots of lines, etc.

I want to sed find/replace the IP address...
Showing results 1 to 3 of 3

 
All times are GMT -4. The time now is 01:38 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy