Skip to content

Instantly share code, notes, and snippets.

View gzxultra's full-sized avatar
🍎
eating apple

Zhixiang gzxultra

🍎
eating apple
  • Seattle, WA
View GitHub Profile
@gzxultra
gzxultra / check_if_file_utf_8.py
Created May 22, 2016 06:05 — forked from binderclip/check_if_file_utf_8.py
simple python script check if file utf-8 coding
import sys
def main():
if len(sys.argv) < 2:
print 'please enter file path'
file_path = sys.argv[1]
with open(file_path, 'r') as f:
s = f.read()
try: