--- a/hgext3rd/topic/__init__.py Tue Aug 23 21:18:47 2016 +0200
+++ b/hgext3rd/topic/__init__.py Fri Aug 26 12:37:52 2016 +0200
@@ -196,6 +196,10 @@
if list:
if clear or change:
raise error.Abort(_("cannot use --clear or --change with --list"))
+ if not topic:
+ topic = repo.currenttopic
+ if not topic:
+ raise error.Abort(_('no active topic to list'))
return stack.showstack(ui, repo, topic, opts)
if change:
@@ -275,6 +279,10 @@
"""list all changesets in a topic
List the current topic by default."""
+ if not topic:
+ topic = repo.currenttopic
+ if not topic:
+ raise error.Abort(_('no active topic to list'))
return stack.showstack(ui, repo, topic, opts)
def _listtopics(ui, repo, opts):