Skip to content

Instantly share code, notes, and snippets.

@dz1984
Created December 16, 2013 04:38
Show Gist options
  • Select an option

  • Save dz1984/7982387 to your computer and use it in GitHub Desktop.

Select an option

Save dz1984/7982387 to your computer and use it in GitHub Desktop.
This script converts file encoding with the Notepad++ Python Script plugin. You need to install a Python Script plugin of Notepad++ before converting file.
import os;
import sys;
filePathSrc="YOUR FILE PATH" # Path to the folder with files to convert
for root, dirs, files in os.walk(filePathSrc):
for fn in files:
if fn[-4:] == '.java': # Specify type of the files
notepad.open(root + "\\" + fn)
notepad.runMenuCommand("Encoding", "Convert to UTF-8 without BOM")
notepad.save()
notepad.close()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment