def is_case_sensitive(path):
 is_case_sensitive = False
 if (not iswindows):
  (name1, name2) = ('calibre_test_case_sensitivity.txt', 'calibre_TesT_CaSe_sensitiVitY.Txt')
  (f1, f2) = (os.path.join(path, name1), os.path.join(path, name2))
  if os.path.exists(f1):
   os.remove(f1)
  open(f1, 'w').close()
  is_case_sensitive = (not os.path.exists(f2))
  os.remove(f1)
 return is_case_sensitive

def is_case_sensitive ( path ) : is_case_sensitive = False if ( not iswindows ) : ( name1 , name2 ) = ( 'calibre_test_case_sensitivity.txt' , 'calibre_TesT_CaSe_sensitiVitY.Txt' ) ( f1 , f2 ) = ( os . path . join ( path , name1 ) , os . path . join ( path , name2 ) ) if os . path . exists ( f1 ) : os . remove ( f1 ) open ( f1 , 'w' ) . close ( ) is_case_sensitive = ( not os . path . exists ( f2 ) ) os . remove ( f1 ) return is_case_sensitive
return true if the filesystem is case sensitive .