diff --git a/mercurial/merge.py b/mercurial/merge.py --- a/mercurial/merge.py +++ b/mercurial/merge.py @@ -1109,10 +1109,7 @@ elif action[0] in nooptypes: del actions[f] # merge does not affect file elif action[0] in nonconflicttypes: - raise error.Abort(_('merge affects file \'%s\' outside narrow, ' - 'which is not yet supported') % f, - hint=_('merging in the other direction ' - 'may work')) + del actions[f] else: raise error.Abort(_('conflict in file \'%s\' is outside ' 'narrow clone') % f) diff --git a/tests/test-narrow-merge.t b/tests/test-narrow-merge.t --- a/tests/test-narrow-merge.t +++ b/tests/test-narrow-merge.t @@ -80,16 +80,14 @@ (no more unresolved files) $ hg commit -m 'merge inside/f1' -TODO: Can merge non-conflicting changes outside narrow spec +Can merge non-conflicting changes outside narrow spec $ hg update -q 'desc("modify inside/f1")' $ hg merge 'desc("modify outside/f1")' - abort: merge affects file 'outside/f1' outside narrow, which is not yet supported (flat !) - abort: merge affects file 'outside/' outside narrow, which is not yet supported (tree !) - (merging in the other direction may work) - [255] + 0 files updated, 0 files merged, 0 files removed, 0 files unresolved + (branch merge, don't forget to commit) - $ hg update -q 'desc("modify outside/f1")' + $ hg update -q 'desc("modify outside/f1")' -C $ hg merge 'desc("modify inside/f1")' 1 files updated, 0 files merged, 0 files removed, 0 files unresolved (branch merge, don't forget to commit)