How to change extension of multiple files from command line?

I have many files with .abc extension and want to change them to .edefg I have a root folder with many sub-folders, so the solution should work -r recursively. find /the/path -depth -name "*.abc" -exec sh -c 'mv "$1" "${1%.abc}.edefg"' _ {} \;