changeset 4737:2ececafa5859

mq: more qdelete help text tweaks
author Brendan Cully <brendan@kublai.com>
date Thu, 28 Jun 2007 09:19:08 -0700
parents 04b2c1e27c26
children c41a404ac387
files hgext/mq.py tests/test-mq-qdelete.out
diffstat 2 files changed, 10 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/mq.py
+++ b/hgext/mq.py
@@ -533,7 +533,8 @@ class queue:
 
     def delete(self, repo, patches, opts):
         if not patches and not opts.get('rev'):
-            raise util.Abort(_('missing patch name'))
+            raise util.Abort(_('qdelete requires at least one revision or '
+                               'patch name'))
 
         realpatches = []
         for patch in patches:
@@ -1383,11 +1384,13 @@ class queue:
 def delete(ui, repo, *patches, **opts):
     """remove patches from queue
 
-    With --rev, mq will stop managing the named revisions. The
-    patches must be applied and at the base of the stack. This option
-    is useful when the patches have been applied upstream.
+    The patches must not be applied, unless they are arguments to
+    the --rev parameter. At least one patch or revision is required.
 
-    Otherwise, the patches must not be applied.
+    With --rev, mq will stop managing the named revisions (converting
+    them to regular mercurial changesets). The patches must be applied
+    and at the base of the stack. This option is useful when the patches
+    have been applied upstream.
 
     With --keep, the patch files are preserved in the patch directory."""
     q = repo.mq
@@ -2109,7 +2112,7 @@ cmdtable = {
         (delete,
          [('k', 'keep', None, _('keep patch file')),
           ('r', 'rev', [], _('stop managing a revision'))],
-         _('hg qdelete [-k] [-r REV]... PATCH...')),
+         _('hg qdelete [-k] [-r REV]... [PATCH]...')),
     'qfold':
         (fold,
          [('e', 'edit', None, _('edit patch header')),
--- a/tests/test-mq-qdelete.out
+++ b/tests/test-mq-qdelete.out
@@ -1,5 +1,5 @@
 adding base
-abort: missing patch name
+abort: qdelete requires at least one revision or patch name
 abort: cannot delete applied patch c
 Now at: b
 a