compare NFC

This commit is contained in:
j 2019-01-14 20:32:34 +05:30
commit 52f45beaec
4 changed files with 11 additions and 7 deletions

View file

@ -15,6 +15,7 @@ import stdnum.isbn
import subprocess
import sys
import time
import unicodedata
import ox
from OpenSSL.crypto import (
@ -462,3 +463,6 @@ def iexists(path):
return False
files = {os.path.basename(f).lower() for f in files}
return name in files
def same_path(f1, f2):
return unicodedata.normalize('NFC', f1) == unicodedata.normalize('NFC', f2)