Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/cmdutil.py @ 23537:f1b06a8aad42
commit: propagate --addremove to subrepos if -S is specified (issue3759)
The recursive addremove operation occurs completely before the first subrepo is
committed. Only hg subrepos support the addremove operation at the moment- svn
and git subrepos will warn and abort the commit.
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Mon, 24 Nov 2014 22:27:49 -0500 |
parents | 72c23fa4f52f |
children | 70a7478c33de |
comparison
equal
deleted
inserted
replaced
23536:fcbc66b5da6a | 23537:f1b06a8aad42 |
---|---|
2200 matcher = scmutil.match(repo[None], pats, opts) | 2200 matcher = scmutil.match(repo[None], pats, opts) |
2201 | 2201 |
2202 # extract addremove carefully -- this function can be called from a command | 2202 # extract addremove carefully -- this function can be called from a command |
2203 # that doesn't support addremove | 2203 # that doesn't support addremove |
2204 if opts.get('addremove'): | 2204 if opts.get('addremove'): |
2205 if scmutil.addremove(repo, matcher, opts) != 0: | 2205 if scmutil.addremove(repo, matcher, "", opts) != 0: |
2206 raise util.Abort( | 2206 raise util.Abort( |
2207 _("failed to mark all new/missing files as added/removed")) | 2207 _("failed to mark all new/missing files as added/removed")) |
2208 | 2208 |
2209 return commitfunc(ui, repo, message, matcher, opts) | 2209 return commitfunc(ui, repo, message, matcher, opts) |
2210 | 2210 |