I want to implement the following command recursively
sed -i 's/href=\"1\//href=\"\/1\//g' ./*
so that it replaces all href="1 with href="/1 in all sub-directories. Is there a flag I can add to this command to achieve the results I want?
find . -type f -print0 | xargs -0 sed -i 's/href=\"1\//href=\"\/1\//g'
Sign up using Google
Sign up using Facebook
Sign up using Stack Exchange
4 years ago