Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 0.8, 0.8.1, and 0.8.2

menuthg: use multiple states form cache

Changeset 5a2a48e63e43

Parent 581ea099d9d7

by Simon Heimberg

Changes to one file · Browse files at 5a2a48e63e43 Showing diff from parent 581ea099d9d7 Diff from another changeset...

 
196
197
198
199
 
200
201
202
203
204
205
206
207
208
 
 
 
209
210
211
 
196
197
198
 
199
200
 
 
 
 
 
 
 
 
201
202
203
204
205
206
@@ -196,16 +196,11 @@
  onlyfiles = False   if f.endswith('.hgignore'):   hashgignore = True - states.add(cachethg.get_state(f, repo)) + states.update(cachethg.get_states(f, repo))   if not files: - if repo.root == os.path.realpath(cwd): - inroot = True - #cache does not return state for root - if not cachethg.overlay_cache: - cachethg.get_state(os.path.join(cwd,'.hg')) - states = set(cachethg.overlay_cache.values()) - else: - states.add(cachethg.get_state(cwd)) + states.update(cachethg.get_states(cwd, repo)) + if cachethg.ROOT in states and len(states) == 1: + states.add(cachethg.MODIFIED)     changed = bool(states & set([cachethg.ADDED, cachethg.MODIFIED]))   modified = cachethg.MODIFIED in states