diff --git a/mercurial/commands.py b/mercurial/commands.py --- a/mercurial/commands.py +++ b/mercurial/commands.py @@ -804,7 +804,8 @@ def docopy(ui, repo, pats, opts): def okaytocopy(abs, rel, exact): reasons = {'?': _('is not managed'), - 'a': _('has been marked for add')} + 'a': _('has been marked for add'), + 'r': _('has been marked for remove')} reason = reasons.get(repo.dirstate.state(abs)) if reason: if exact: diff --git a/tests/test-rename b/tests/test-rename --- a/tests/test-rename +++ b/tests/test-rename @@ -152,3 +152,9 @@ echo "# move the parent tree with \"hg r (cd d1/d11; hg rename .. ../../d3) hg status hg update -C + +echo "# skip removed files" +hg remove d1/b +hg rename d1 d3 +hg status +hg update -C diff --git a/tests/test-rename.out b/tests/test-rename.out --- a/tests/test-rename.out +++ b/tests/test-rename.out @@ -232,3 +232,17 @@ R d1/a R d1/b R d1/ba R d1/d11/a1 +# skip removed files +copying d1/a to d3/a +copying d1/ba to d3/ba +copying d1/d11/a1 to d3/d11/a1 +removing d1/a +removing d1/ba +removing d1/d11/a1 +A d3/a +A d3/ba +A d3/d11/a1 +R d1/a +R d1/b +R d1/ba +R d1/d11/a1