@@ -576,15 +576,22 @@ class PluginManager:
576576 max_key_len = max (map (len , self .plug_by_name .keys ()))
577577 min_indent_len = 8
578578 description_indent = max_key_len + min_indent_len
579- for key , plugin in sorted (self .plug_by_name .items ()):
580- props = plugin .get_props ()
581- desc = getattr (props , "description" , "" )
582- if not getattr (props , "stable" , False ):
583- # highlight the fact that the plug-in is experimental
584- desc = "[EXPERIMENTAL] " + desc
585- sys .stdout .write ("{}{}{}\n " .format (
586- key , " " * (description_indent - len (key )),
587- desc .replace ('\n ' , '\n %s' % (" " * description_indent ))))
579+
580+ def list_plugins (stable ):
581+ for key , plugin in sorted (self .plug_by_name .items ()):
582+ props = plugin .get_props ()
583+ desc = getattr (props , "description" , "" )
584+ if stable != getattr (props , "stable" , False ):
585+ continue
586+ if not stable :
587+ # highlight the fact that the plug-in is experimental
588+ desc = "[EXPERIMENTAL] " + desc
589+ sys .stdout .write ("{}{}{}\n " .format (
590+ key , " " * (description_indent - len (key )),
591+ desc .replace ('\n ' , '\n %s' % (" " * description_indent ))))
592+
593+ list_plugins (stable = True )
594+ list_plugins (stable = False )
588595
589596 def get_name_list (self ):
590597 return sorted (self .plug_by_name .keys ())
0 commit comments