我刚刚在 FreeBSD 服务器上上传了一些文件。有些文件的???
名称中有 。这些文件来自 Windows 机器,所以我尝试这样做:
$ convmv -f cp850 -t utf-8 *
Starting a dry run without changes...
mv "./??-145x145.jpg" "./íª-145x145.jpg"
mv "./??-150x104.jpg" "./íª-150x104.jpg"
mv "./??-150x150.jpg" "./íª-150x150.jpg"
mv "./??-220x145.jpg" "./íª-220x145.jpg"
mv "./??-225x145.jpg" "./íª-225x145.jpg"
mv "./??-380x245.jpg" "./íª-380x245.jpg"
mv "./??-570x396.jpg" "./íª-570x396.jpg"
convmv
找到文件,但是在尝试将编码更改为 utf-8 时仍然无法获取名称。有任何想法吗?
答案1
您需要使用--notest
:
convmv --notest -f cp850 -t utf-8 ./*
从转换手册:
--notest
Needed to actually rename the files. By default convmv will just
print what it wants to do.