Details
Details
Diff Detail
Diff Detail
- Repository
- rHG Mercurial
- Lint
Lint Skipped - Unit
Unit Tests Skipped
| Lint Skipped |
| Unit Tests Skipped |
| Path | Packages | |||
|---|---|---|---|---|
| M | mercurial/commands.py (5 lines) | |||
| M | tests/test-resolve.t (3 lines) |
| Commit | Parents | Author | Summary | Date |
|---|---|---|---|---|
| Martin von Zweigbergk | Jan 29 2019, 3:01 PM |
| Status | Author | Revision | |
|---|---|---|---|
| Closed | martinvonz | ||
| Closed | martinvonz | ||
| Closed | martinvonz | ||
| Closed | martinvonz | ||
| Closed | martinvonz | ||
| Closed | martinvonz | ||
| Closed | martinvonz |
| if ui.promptchoice(_(b'mark all unresolved files as resolved (yn)?' | if ui.promptchoice(_(b'mark all unresolved files as resolved (yn)?' | ||||
| b'$$ &Yes $$ &No')): | b'$$ &Yes $$ &No')): | ||||
| raise error.Abort(_('user quit')) | raise error.Abort(_('user quit')) | ||||
| if unmark and not pats: | if unmark and not pats: | ||||
| if ui.promptchoice(_(b'mark all resolved files as unresolved (yn)?' | if ui.promptchoice(_(b'mark all resolved files as unresolved (yn)?' | ||||
| b'$$ &Yes $$ &No')): | b'$$ &Yes $$ &No')): | ||||
| raise error.Abort(_('user quit')) | raise error.Abort(_('user quit')) | ||||
| uipathfn = scmutil.getuipathfn(repo) | |||||
| if show: | if show: | ||||
| ui.pager('resolve') | ui.pager('resolve') | ||||
| fm = ui.formatter('resolve', opts) | fm = ui.formatter('resolve', opts) | ||||
| ms = mergemod.mergestate.read(repo) | ms = mergemod.mergestate.read(repo) | ||||
| wctx = repo[None] | wctx = repo[None] | ||||
| m = scmutil.match(wctx, pats, opts) | m = scmutil.match(wctx, pats, opts) | ||||
| # Labels and keys based on merge state. Unresolved path conflicts show | # Labels and keys based on merge state. Unresolved path conflicts show | ||||
| for f in ms: | for f in ms: | ||||
| if not m(f): | if not m(f): | ||||
| continue | continue | ||||
| label, key = mergestateinfo[ms[f]] | label, key = mergestateinfo[ms[f]] | ||||
| fm.startitem() | fm.startitem() | ||||
| fm.context(ctx=wctx) | fm.context(ctx=wctx) | ||||
| fm.condwrite(not nostatus, 'mergestatus', '%s ', key, label=label) | fm.condwrite(not nostatus, 'mergestatus', '%s ', key, label=label) | ||||
| fm.write('path', '%s\n', f, label=label) | fm.data(path=f) | ||||
| fm.plain('%s\n' % uipathfn(f), label=label) | |||||
| fm.end() | fm.end() | ||||
| return 0 | return 0 | ||||
| with repo.wlock(): | with repo.wlock(): | ||||
| ms = mergemod.mergestate.read(repo) | ms = mergemod.mergestate.read(repo) | ||||
| if not (ms.active() or repo.dirstate.p2() != nullid): | if not (ms.active() or repo.dirstate.p2() != nullid): | ||||
| raise error.Abort( | raise error.Abort( | ||||
| (try: hg resolve -m path:file1) | (try: hg resolve -m path:file1) | ||||
| $ hg resolve -m file1 filez | $ hg resolve -m file1 filez | ||||
| arguments do not match paths that need resolving | arguments do not match paths that need resolving | ||||
| (try: hg resolve -m path:file1 path:filez) | (try: hg resolve -m path:file1 path:filez) | ||||
| $ hg resolve -m path:file1 path:filez | $ hg resolve -m path:file1 path:filez | ||||
| $ hg resolve -l | $ hg resolve -l | ||||
| R file1 | R file1 | ||||
| U file2 | U file2 | ||||
| $ hg resolve -l --config ui.relative-paths=yes | |||||
| R ../file1 | |||||
| U ../file2 | |||||
| $ hg resolve --re-merge filez file2 | $ hg resolve --re-merge filez file2 | ||||
| arguments do not match paths that need resolving | arguments do not match paths that need resolving | ||||
| (try: hg resolve --re-merge path:filez path:file2) | (try: hg resolve --re-merge path:filez path:file2) | ||||
| $ hg resolve -m filez file2 | $ hg resolve -m filez file2 | ||||
| arguments do not match paths that need resolving | arguments do not match paths that need resolving | ||||
| (try: hg resolve -m path:filez path:file2) | (try: hg resolve -m path:filez path:file2) | ||||
| $ hg resolve -m path:filez path:file2 | $ hg resolve -m path:filez path:file2 | ||||
| (no more unresolved files) | (no more unresolved files) | ||||