diff hgext/mq.py @ 3604:437489d8dfbf

mq: handle qpush -a with empty series
author Brendan Cully <brendan@kublai.com>
date Tue, 31 Oct 2006 17:24:42 -0800
parents 3b4e00cba57a
children 05d877dfd33d
line wrap: on
line diff
--- a/hgext/mq.py	Tue Oct 31 16:35:44 2006 -0800
+++ b/hgext/mq.py	Tue Oct 31 17:24:42 2006 -0800
@@ -1731,6 +1731,8 @@
     mergeq = None
 
     if opts['all']:
+        if not q.series:
+            raise util.Abort(_('no patches in series'))
         patch = q.series[-1]
     if opts['merge']:
         if opts['name']: