mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-05-08 13:22:45 +02:00
samefile_windows(); Return true if the strings are the same upto case differences.
This commit is contained in:
parent
847e906001
commit
80300df3f4
1 changed files with 5 additions and 0 deletions
|
|
@ -203,6 +203,11 @@ def samefile_windows(src, dst):
|
|||
import win32file
|
||||
from pywintypes import error
|
||||
|
||||
samestring = (os.path.normcase(os.path.abspath(src)) ==
|
||||
os.path.normcase(os.path.abspath(dst)))
|
||||
if samestring:
|
||||
return True
|
||||
|
||||
def get_fileid(x):
|
||||
if isbytestring(x): x = x.decode(filesystem_encoding)
|
||||
try:
|
||||
|
|
|
|||
Loading…
Reference in a new issue