I've got a crappy webhoster where I need the filenames in iso-8859-1, my FS uses utf-8. Filezilla can handle encodings, but I need something that I can use in a script. Is there a program out there that I can use to convert file names on upload that can be called from bash?
Tell me more
×
Super User is a question and answer site for
computer enthusiasts and power users. It's 100% free, no registration required.
|
I think there are ways to script FileZilla but I'm not too familiar with them. Try that first. If not, what I can suggest is using lftp instead. With lftp you can do the following:
and from there, upload the file. Hope that helps! |
|||||||
|
|
convmv --notest -r -t iso8859-1 ./upload-queue/ Alternatively, hack something up using srcfile=... dstfile=$(echo "$srcfile" | iconv -t iso8859-1) some-upload-command "$srcfile" "ftpserver:$dstfile" |
|||
|
|