Move definition of ENCODER to after parsing args
Import unicode_literals from __future__
Run 2to3
Make git ignore scripts/ dir
 Make code compatible with versions >=2.7.0