Changeset e15912d5e66b…
Parent 03cdd729ccf5…
by
Changes to one file · Browse files at e15912d5e66b Showing diff from parent 03cdd729ccf5 Diff from another changeset...
@@ -210,16 +210,12 @@ if self.pats:
m = cmdutil.match(self.repo, self.pats)
status = self.repo.status(match=m, **stopts)
- # Remove unwanted files before checking them
- if not self.opts['modified']:
- status[0] = []
- if not self.opts['added']:
- status[1] = []
- if not self.opts['removed']:
- status[2] = []
# Record all matched files as initially checked
- self.patchecked = dict([(fn, True) for group in status \
- for fn in group])
+ for i, stat in enumerate(StatusType.preferredOrder):
+ val = statusTypes[stat]
+ if self.opts[val.name]:
+ d = dict([(fn, True) for fn in status[i]])
+ self.patchecked.update(d)
wctx = context.workingctx(self.repo, changes=status)
else:
wctx = self.repo[None]
|
Loading...