Mercurial > public > mercurial-scm > hg
comparison mercurial/filemerge.py @ 29775:978b907d9b36
merge: always use other, not remote, in user prompts
Now that we store and display merge labels in user prompts (not just
conflict markets), we should rely on labels to clarify the two sides of a
merge operation (hg merge, hg update, hg rebase etc).
"remote" is not a great name here, as it conflates "remote" as in "remote
server" with "remote" as in "the side of the merge that's further away". In
cases where you're merging the "wrong way" around, remote can even be the
"local" commit that you're merging with something pulled from the remote
server.
author | Simon Farnsworth <simonfar@fb.com> |
---|---|
date | Fri, 12 Aug 2016 05:56:40 -0700 |
parents | a7f8939641aa |
children | aa23c93e636d |
comparison
equal
deleted
inserted
replaced
29774:a7f8939641aa | 29775:978b907d9b36 |
---|---|
239 prompts = partextras(labels) | 239 prompts = partextras(labels) |
240 prompts['fd'] = fd | 240 prompts['fd'] = fd |
241 try: | 241 try: |
242 if fco.isabsent(): | 242 if fco.isabsent(): |
243 index = ui.promptchoice( | 243 index = ui.promptchoice( |
244 _("local%(l)s changed %(fd)s which remote%(o)s deleted\n" | 244 _("local%(l)s changed %(fd)s which other%(o)s deleted\n" |
245 "use (c)hanged version, (d)elete, or leave (u)nresolved?" | 245 "use (c)hanged version, (d)elete, or leave (u)nresolved?" |
246 "$$ &Changed $$ &Delete $$ &Unresolved") % prompts, 2) | 246 "$$ &Changed $$ &Delete $$ &Unresolved") % prompts, 2) |
247 choice = ['local', 'other', 'unresolved'][index] | 247 choice = ['local', 'other', 'unresolved'][index] |
248 elif fcd.isabsent(): | 248 elif fcd.isabsent(): |
249 index = ui.promptchoice( | 249 index = ui.promptchoice( |
250 _("remote%(o)s changed %(fd)s which local%(l)s deleted\n" | 250 _("other%(o)s changed %(fd)s which local%(l)s deleted\n" |
251 "use (c)hanged version, leave (d)eleted, or " | 251 "use (c)hanged version, leave (d)eleted, or " |
252 "leave (u)nresolved?" | 252 "leave (u)nresolved?" |
253 "$$ &Changed $$ &Deleted $$ &Unresolved") % prompts, 2) | 253 "$$ &Changed $$ &Deleted $$ &Unresolved") % prompts, 2) |
254 choice = ['other', 'local', 'unresolved'][index] | 254 choice = ['other', 'local', 'unresolved'][index] |
255 else: | 255 else: |