Show More
@@ -664,6 +664,8 b' def tag(repo, subset, x):' | |||||
664 | tn = getstring(args[0], |
|
664 | tn = getstring(args[0], | |
665 | # i18n: "tag" is a keyword |
|
665 | # i18n: "tag" is a keyword | |
666 | _('the argument to tag must be a string')) |
|
666 | _('the argument to tag must be a string')) | |
|
667 | if not repo.tags().get(tn, None): | |||
|
668 | raise util.Abort(_("tag '%s' does not exist") % tn) | |||
667 | s = set([cl.rev(n) for t, n in repo.tagslist() if t == tn]) |
|
669 | s = set([cl.rev(n) for t, n in repo.tagslist() if t == tn]) | |
668 | else: |
|
670 | else: | |
669 | s = set([cl.rev(n) for t, n in repo.tagslist() if t != 'tip']) |
|
671 | s = set([cl.rev(n) for t, n in repo.tagslist() if t != 'tip']) | |
@@ -683,8 +685,9 b' def bookmark(repo, subset, x):' | |||||
683 | # i18n: "bookmark" is a keyword |
|
685 | # i18n: "bookmark" is a keyword | |
684 | _('the argument to bookmark must be a string')) |
|
686 | _('the argument to bookmark must be a string')) | |
685 | bmrev = bookmarksmod.listbookmarks(repo).get(bm, None) |
|
687 | bmrev = bookmarksmod.listbookmarks(repo).get(bm, None) | |
686 | if bmrev: |
|
688 | if not bmrev: | |
687 | bmrev = repo[bmrev].rev() |
|
689 | raise util.Abort(_("bookmark '%s' does not exist") % bm) | |
|
690 | bmrev = repo[bmrev].rev() | |||
688 | return [r for r in subset if r == bmrev] |
|
691 | return [r for r in subset if r == bmrev] | |
689 | bms = set([repo[r].rev() |
|
692 | bms = set([repo[r].rev() | |
690 | for r in bookmarksmod.listbookmarks(repo).values()]) |
|
693 | for r in bookmarksmod.listbookmarks(repo).values()]) |
General Comments 0
You need to be logged in to leave comments.
Login now