Find and replace

find . -depth -type d -name <source_directory> -execdir mv {} <target_directory> \; find . -name <source_file>.* | sed -e "p;s/<source_file>/<target_file>/" | xargs -n2 mv find . -type f -name *.*" -print0 | xargs -0 sed -i '' -e 's/<source_string>/<target_string>/g'

Be the first to comment

You can use [html][/html], [css][/css], [php][/php] and more to embed the code. Urls are automatically hyperlinked. Line breaks and paragraphs are automatically generated.