I need to do a substitution on a bunch of files so I tried
But I get this error
There are no complaints when I don't pass any option, but it doesn't replace anything in that case either. Anyone know how I can use sed to find replace or any other options?
find . -type f -exec sed -i 's/regex/replacement/g' {} \;
But I get this error
Code:
sed: 1: "piece of file name": invalid command code .
There are no complaints when I don't pass any option, but it doesn't replace anything in that case either. Anyone know how I can use sed to find replace or any other options?