如何为目录中的每个文件添加文件扩展名
此 shell 脚本将递归重命名目录中的每个文件,并向其文件名添加 .docx 扩展名(即使已有扩展名),通过 mv --backup=numbered 防止覆盖同名的现有文件:
add_extension_recursive.sh
find . -type f -exec mv -v --backup=numbered "{}" "{}.docx" \;Check out similar posts by category:
Allgemein
If this post helped you, please consider buying me a coffee or donating via PayPal to support research & publishing of new posts on TechOverflow