Show More
@@ -496,7 +496,8 b' def bookmark(repo, subset, x):' | |||
|
496 | 496 | if kind == 'literal': |
|
497 | 497 | bmrev = repo._bookmarks.get(pattern, None) |
|
498 | 498 | if not bmrev: |
|
499 |
raise |
|
|
499 | raise error.RepoLookupError(_("bookmark '%s' does not exist") | |
|
500 | % bm) | |
|
500 | 501 | bms.add(repo[bmrev].rev()) |
|
501 | 502 | else: |
|
502 | 503 | matchrevs = set() |
@@ -504,8 +505,8 b' def bookmark(repo, subset, x):' | |||
|
504 | 505 | if matcher(name): |
|
505 | 506 | matchrevs.add(bmrev) |
|
506 | 507 | if not matchrevs: |
|
507 |
raise |
|
|
508 | % pattern) | |
|
508 | raise error.RepoLookupError(_("no bookmarks exist" | |
|
509 | " that match '%s'") % pattern) | |
|
509 | 510 | for bmrev in matchrevs: |
|
510 | 511 | bms.add(repo[bmrev].rev()) |
|
511 | 512 | else: |
@@ -1262,15 +1263,16 b' def named(repo, subset, x):' | |||
|
1262 | 1263 | namespaces = set() |
|
1263 | 1264 | if kind == 'literal': |
|
1264 | 1265 | if pattern not in repo.names: |
|
1265 |
raise |
|
|
1266 | raise error.RepoLookupError(_("namespace '%s' does not exist") | |
|
1267 | % ns) | |
|
1266 | 1268 | namespaces.add(repo.names[pattern]) |
|
1267 | 1269 | else: |
|
1268 | 1270 | for name, ns in repo.names.iteritems(): |
|
1269 | 1271 | if matcher(name): |
|
1270 | 1272 | namespaces.add(ns) |
|
1271 | 1273 | if not namespaces: |
|
1272 |
raise |
|
|
1273 | % pattern) | |
|
1274 | raise error.RepoLookupError(_("no namespace exists" | |
|
1275 | " that match '%s'") % pattern) | |
|
1274 | 1276 | |
|
1275 | 1277 | names = set() |
|
1276 | 1278 | for ns in namespaces: |
@@ -1816,7 +1818,8 b' def tag(repo, subset, x):' | |||
|
1816 | 1818 | # avoid resolving all tags |
|
1817 | 1819 | tn = repo._tagscache.tags.get(pattern, None) |
|
1818 | 1820 | if tn is None: |
|
1819 |
raise |
|
|
1821 | raise error.RepoLookupError(_("tag '%s' does not exist") | |
|
1822 | % pattern) | |
|
1820 | 1823 | s = set([repo[tn].rev()]) |
|
1821 | 1824 | else: |
|
1822 | 1825 | s = set([cl.rev(n) for t, n in repo.tagslist() if matcher(t)]) |
@@ -133,8 +133,13 b' bookmarks revset' | |||
|
133 | 133 | |
|
134 | 134 | |
|
135 | 135 | $ hg log -r 'bookmark(unknown)' |
|
136 | abort: bookmark 'unknown' does not exist | |
|
136 | abort: bookmark 'unknown' does not exist! | |
|
137 | 137 | [255] |
|
138 | $ hg log -r 'bookmark("re:unknown")' | |
|
139 | abort: no bookmarks exist that match 'unknown'! | |
|
140 | [255] | |
|
141 | $ hg log -r 'present(bookmark("literal:unknown"))' | |
|
142 | $ hg log -r 'present(bookmark("re:unknown"))' | |
|
138 | 143 | |
|
139 | 144 | $ hg help revsets | grep 'bookmark(' |
|
140 | 145 | "bookmark([name])" |
@@ -709,7 +709,7 b' check that conversion to only works' | |||
|
709 | 709 | we can use patterns when searching for tags |
|
710 | 710 | |
|
711 | 711 | $ log 'tag("1..*")' |
|
712 | abort: tag '1..*' does not exist | |
|
712 | abort: tag '1..*' does not exist! | |
|
713 | 713 | [255] |
|
714 | 714 | $ log 'tag("re:1..*")' |
|
715 | 715 | 6 |
@@ -720,11 +720,17 b' we can use patterns when searching for t' | |||
|
720 | 720 | $ log 'tag("re:0..*")' |
|
721 | 721 | |
|
722 | 722 | $ log 'tag(unknown)' |
|
723 | abort: tag 'unknown' does not exist | |
|
723 | abort: tag 'unknown' does not exist! | |
|
724 | 724 | [255] |
|
725 | $ log 'tag("re:unknown")' | |
|
726 | $ log 'present(tag("unknown"))' | |
|
727 | $ log 'present(tag("re:unknown"))' | |
|
725 | 728 | $ log 'branch(unknown)' |
|
726 | 729 | abort: unknown revision 'unknown'! |
|
727 | 730 | [255] |
|
731 | $ log 'branch("re:unknown")' | |
|
732 | $ log 'present(branch("unknown"))' | |
|
733 | $ log 'present(branch("re:unknown"))' | |
|
728 | 734 | $ log 'user(bob)' |
|
729 | 735 | 2 |
|
730 | 736 | |
@@ -772,6 +778,15 b' we can use patterns when searching for t' | |||
|
772 | 778 | 3 |
|
773 | 779 | 1 |
|
774 | 780 | |
|
781 | $ log 'named("unknown")' | |
|
782 | abort: namespace 'unknown' does not exist! | |
|
783 | [255] | |
|
784 | $ log 'named("re:unknown")' | |
|
785 | abort: no namespace exists that match 'unknown'! | |
|
786 | [255] | |
|
787 | $ log 'present(named("unknown"))' | |
|
788 | $ log 'present(named("re:unknown"))' | |
|
789 | ||
|
775 | 790 | issue2437 |
|
776 | 791 | |
|
777 | 792 | $ log '3 and p1(5)' |
General Comments 0
You need to be logged in to leave comments.
Login now