Mercurial > public > mercurial-scm > hg
comparison mercurial/commands.py @ 1634:f49f602fae92
copy & rename can ignore removed source files
As mercurial now distinguishes deleted files from removed files,
we can skip removed source files while copying or renaming.
author | Robin Farine <robin.farine@terminus.org> |
---|---|
date | Tue, 24 Jan 2006 13:59:01 +1300 |
parents | 94c179a92f4a |
children | 3b1b44b917f4 |
comparison
equal
deleted
inserted
replaced
1633:94c179a92f4a | 1634:f49f602fae92 |
---|---|
802 copied = [] | 802 copied = [] |
803 targets = {} | 803 targets = {} |
804 | 804 |
805 def okaytocopy(abs, rel, exact): | 805 def okaytocopy(abs, rel, exact): |
806 reasons = {'?': _('is not managed'), | 806 reasons = {'?': _('is not managed'), |
807 'a': _('has been marked for add')} | 807 'a': _('has been marked for add'), |
808 'r': _('has been marked for remove')} | |
808 reason = reasons.get(repo.dirstate.state(abs)) | 809 reason = reasons.get(repo.dirstate.state(abs)) |
809 if reason: | 810 if reason: |
810 if exact: | 811 if exact: |
811 ui.warn(_('%s: not copying - file %s\n') % (rel, reason)) | 812 ui.warn(_('%s: not copying - file %s\n') % (rel, reason)) |
812 else: | 813 else: |