Com o GNU find:
cd experiment
find . -name "foo.txt" -exec echo cp -v source-foo.txt {} \;
Se tudo estiver correto, remova echo
.
Saída com echo
:
cp -v source-foo.txt ./foo.txt cp -v source-foo.txt ./subdir/foo.txt
Saída sem echo
:
'source-foo.txt' -> './foo.txt' 'source-foo.txt' -> './subdir/foo.txt'