Show More
@@ -22,7 +22,6 b' class dirstate(object):' | |||||
22 | self.root = root |
|
22 | self.root = root | |
23 | self.dirty = 0 |
|
23 | self.dirty = 0 | |
24 | self.ui = ui |
|
24 | self.ui = ui | |
25 | self._slash = None |
|
|||
26 |
|
25 | |||
27 | def __getattr__(self, name): |
|
26 | def __getattr__(self, name): | |
28 | if name == 'map': |
|
27 | if name == 'map': | |
@@ -56,6 +55,9 b' class dirstate(object):' | |||||
56 | files = [self.wjoin('.hgignore')] + self.ui.hgignorefiles() |
|
55 | files = [self.wjoin('.hgignore')] + self.ui.hgignorefiles() | |
57 | self._ignore = ignore.ignore(self.root, files, self.ui.warn) |
|
56 | self._ignore = ignore.ignore(self.root, files, self.ui.warn) | |
58 | return self._ignore |
|
57 | return self._ignore | |
|
58 | elif name == '_slash': | |||
|
59 | self._slash = self.ui.configbool('ui', 'slash') and os.sep != '/' | |||
|
60 | return self._slash | |||
59 | else: |
|
61 | else: | |
60 | raise AttributeError, name |
|
62 | raise AttributeError, name | |
61 |
|
63 | |||
@@ -79,10 +81,8 b' class dirstate(object):' | |||||
79 | if cwd is None: |
|
81 | if cwd is None: | |
80 | cwd = self.getcwd() |
|
82 | cwd = self.getcwd() | |
81 | path = util.pathto(self.root, cwd, f) |
|
83 | path = util.pathto(self.root, cwd, f) | |
82 | if self._slash is None: |
|
|||
83 | self._slash = self.ui.configbool('ui', 'slash') and os.sep != '/' |
|
|||
84 | if self._slash: |
|
84 | if self._slash: | |
85 |
|
|
85 | return path.replace(os.sep, '/') | |
86 | return path |
|
86 | return path | |
87 |
|
87 | |||
88 | def __del__(self): |
|
88 | def __del__(self): |
General Comments 0
You need to be logged in to leave comments.
Login now