Plugins/VcsPlugins/vcsMercurial/hg.py

changeset 240
b0d829cf4234
parent 219
0553aa793753
child 248
f4561c24989a
equal deleted inserted replaced
239:734a7fa843df 240:b0d829cf4234
790 @param name filename to check (string) 790 @param name filename to check (string)
791 @return a combination of canBeCommited and canBeAdded 791 @return a combination of canBeCommited and canBeAdded
792 """ 792 """
793 if name.endswith(os.sep): 793 if name.endswith(os.sep):
794 name = name[:-1] 794 name = name[:-1]
795 name = os.path.normcase(name)
795 dname, fname = self.splitPath(name) 796 dname, fname = self.splitPath(name)
796 797
797 if fname == '.' and os.path.isdir(os.path.join(dname, self.adminDir)): 798 if fname == '.' and os.path.isdir(os.path.join(dname, self.adminDir)):
798 return self.canBeCommitted 799 return self.canBeCommitted
799 800
824 for line in output.splitlines(): 825 for line in output.splitlines():
825 flag, path = line.split(" ", 1) 826 flag, path = line.split(" ", 1)
826 absname = os.path.join(repodir, os.path.normcase(path)) 827 absname = os.path.join(repodir, os.path.normcase(path))
827 if flag not in "?I": 828 if flag not in "?I":
828 if fname == '.': 829 if fname == '.':
829 if absname.startswith(dname): 830 if absname.startswith(dname + os.path.sep):
831 return self.canBeCommitted
832 if absname == dname:
830 return self.canBeCommitted 833 return self.canBeCommitted
831 else: 834 else:
832 if absname == name: 835 if absname == name:
833 return self.canBeCommitted 836 return self.canBeCommitted
834 837

eric ide

mercurial