614 shaares
Ok, so there's no fucking way to sanitize filenames out there?
I've been mainly looking for Python solutions but still it feels like there is none.
I mean, I'm talking about solutions that would be offered by the system itself, so that you don't have to code a sanitizer yourself for each existing os possible.
Doh!
EDIT: This is a nice solution if you don't care both about loosing completely (but reversible) the original filename and readability for humans.
http://stackoverflow.com/a/295150/1524913
I've been mainly looking for Python solutions but still it feels like there is none.
I mean, I'm talking about solutions that would be offered by the system itself, so that you don't have to code a sanitizer yourself for each existing os possible.
Doh!
EDIT: This is a nice solution if you don't care both about loosing completely (but reversible) the original filename and readability for humans.
http://stackoverflow.com/a/295150/1524913