mercurial/discovery.py
changeset 29973 4ddb05751b12
parent 29901 4d1e6f91f1c7
child 31586 df82f375fa00
equal deleted inserted replaced
29972:392edab93b8a 29973:4ddb05751b12
   399                 dhs = list(newhs)
   399                 dhs = list(newhs)
   400                 if errormsg is None:
   400                 if errormsg is None:
   401                     errormsg = (_("push creates new branch '%s' "
   401                     errormsg = (_("push creates new branch '%s' "
   402                                   "with multiple heads") % (branch))
   402                                   "with multiple heads") % (branch))
   403                     hint = _("merge or"
   403                     hint = _("merge or"
   404                              " see \"hg help push\" for details about"
   404                              " see 'hg help push' for details about"
   405                              " pushing new heads")
   405                              " pushing new heads")
   406         elif len(newhs) > len(oldhs):
   406         elif len(newhs) > len(oldhs):
   407             # remove bookmarked or existing remote heads from the new heads list
   407             # remove bookmarked or existing remote heads from the new heads list
   408             dhs = sorted(newhs - nowarnheads - oldhs)
   408             dhs = sorted(newhs - nowarnheads - oldhs)
   409         if dhs:
   409         if dhs:
   418                 else:
   418                 else:
   419                     errormsg = _("push creates new remote head %s!"
   419                     errormsg = _("push creates new remote head %s!"
   420                                  ) % short(dhs[0])
   420                                  ) % short(dhs[0])
   421                 if unsyncedheads:
   421                 if unsyncedheads:
   422                     hint = _("pull and merge or"
   422                     hint = _("pull and merge or"
   423                              " see \"hg help push\" for details about"
   423                              " see 'hg help push' for details about"
   424                              " pushing new heads")
   424                              " pushing new heads")
   425                 else:
   425                 else:
   426                     hint = _("merge or"
   426                     hint = _("merge or"
   427                              " see \"hg help push\" for details about"
   427                              " see 'hg help push' for details about"
   428                              " pushing new heads")
   428                              " pushing new heads")
   429             if branch is None:
   429             if branch is None:
   430                 repo.ui.note(_("new remote heads:\n"))
   430                 repo.ui.note(_("new remote heads:\n"))
   431             else:
   431             else:
   432                 repo.ui.note(_("new remote heads on branch '%s':\n") % branch)
   432                 repo.ui.note(_("new remote heads on branch '%s':\n") % branch)