[PATCH] mq: don't suggest to refresh when qpushing with no applied patches
Idan Kamara
idankk86 at gmail.com
Wed May 4 15:12:43 CDT 2011
# HG changeset patch
# User Idan Kamara <idankk86 at gmail.com>
# Date 1304539943 -10800
# Node ID 437c87982e79b2d7e9af9f433c06b86463f96f34
# Parent 333def42e785fddda47dd097c0648abb105e399a
mq: don't suggest to refresh when qpushing with no applied patches
diff -r 333def42e785 -r 437c87982e79 hgext/mq.py
--- a/hgext/mq.py Wed May 04 08:21:50 2011 -0500
+++ b/hgext/mq.py Wed May 04 23:12:23 2011 +0300
@@ -1127,7 +1127,7 @@
self.ui.warn(_('patch series already fully applied\n'))
return 1
if not force:
- self.check_localchanges(repo)
+ self.check_localchanges(repo, refresh=self.applied)
if exact:
if move:
diff -r 333def42e785 -r 437c87982e79 tests/test-mq-qpush-exact.t
--- a/tests/test-mq-qpush-exact.t Wed May 04 08:21:50 2011 -0500
+++ b/tests/test-mq-qpush-exact.t Wed May 04 23:12:23 2011 +0300
@@ -163,7 +163,7 @@
$ hg update 1 -q
$ echo c0 >> f0
$ hg qpush -e
- abort: local changes found, refresh first
+ abort: local changes found
[255]
$ hg qpush -ef
applying p0
@@ -178,7 +178,7 @@
$ hg update 1 -q
$ echo c0 >> f0
$ hg qpush -e p1
- abort: local changes found, refresh first
+ abort: local changes found
[255]
$ hg qpush -e p1 -f
applying p0
@@ -197,7 +197,7 @@
$ echo cp0-bad >> fp0
$ hg add fp0
$ hg qpush -e
- abort: local changes found, refresh first
+ abort: local changes found
[255]
$ hg qpush -ef
applying p0
@@ -223,7 +223,7 @@
$ echo cp1-bad >> fp1
$ hg add fp1
$ hg qpush -e p1
- abort: local changes found, refresh first
+ abort: local changes found
[255]
$ hg qpush -e p1 -f
applying p0
diff -r 333def42e785 -r 437c87982e79 tests/test-mq.t
--- a/tests/test-mq.t Wed May 04 08:21:50 2011 -0500
+++ b/tests/test-mq.t Wed May 04 23:12:23 2011 +0300
@@ -1271,7 +1271,7 @@
qpush should fail, local changes
$ hg qpush
- abort: local changes found, refresh first
+ abort: local changes found
[255]
@@ -1317,7 +1317,7 @@
qpush should fail, local changes
$ hg qpush
- abort: local changes found, refresh first
+ abort: local changes found
[255]
More information about the Mercurial-devel
mailing list