Mercurial > repo
view bin/toutf8 @ 4004:c08a49fca968
<mrhmouse> wget http://nodejs.org/dist/v0.10.22/node-v0.10.22-linux-x64.tar.gz -O node.tar.gz
author | HackBot |
---|---|
date | Wed, 13 Nov 2013 16:29:23 +0000 |
parents | e037173e0012 |
children |
line wrap: on
line source
#!/usr/bin/python import sys import chardet x = sys.stdin.read() enc = chardet.detect(x)['encoding'] sys.stdout.write(x.decode(enc).encode('UTF-8'))