diff mercurial/commands.py @ 15404:c1eb8398fe82

localrepo: convert various repo.set() users to repo.revs()
author Matt Mackall <mpm@selenic.com>
date Wed, 02 Nov 2011 13:51:16 -0500
parents c519cd8f0169
children e4a17bb8472f
line wrap: on
line diff
--- a/mercurial/commands.py	Wed Nov 02 13:37:34 2011 -0500
+++ b/mercurial/commands.py	Wed Nov 02 13:51:16 2011 -0500
@@ -2534,16 +2534,16 @@
         revs = scmutil.revrange(repo, revs)
 
     # check for merges
-    for ctx in repo.set('%ld and merge()', revs):
-        ui.warn(_('skipping ungraftable merge revision %s\n') % ctx.rev())
-        revs.remove(ctx.rev())
+    for rev in repo.revs('%ld and merge()', revs):
+        ui.warn(_('skipping ungraftable merge revision %s\n') % rev)
+        revs.remove(rev)
     if not revs:
         return -1
 
     # check for ancestors of dest branch
-    for ctx in repo.set('::. and %ld', revs):
-        ui.warn(_('skipping ancestor revision %s\n') % ctx.rev())
-        revs.remove(ctx.rev())
+    for rev in repo.revs('::. and %ld', revs):
+        ui.warn(_('skipping ancestor revision %s\n') % rev)
+        revs.remove(rev)
     if not revs:
         return -1