docs: def cli_plugin(func=None, **kwargs):
      """
      Decorator that wraps the given function in a :class:`CLIPlugin`
  
      Args:
          func (callable): function/class to decorate
          **kwargs: Any other arg to use when initializing the parser (like help,
              or prefix_chars)
  
      Returns:
          CLIPlugin: cli plugin that handles that method
  
      Notes:
          It can be used as a decorator or as a decorator generator, if used as a
          decorator generator don't pass any parameters
  
      Examples:
          >>> @cli_plugin
          ... def test(**kwargs):
          ...     print 'test'
          ...
          >>> print test.__class__
          <class 'cli.CLIPluginFuncWrapper'>
  
          >>> @cli_plugin()
          ... def test(**kwargs):
          ...     print 'test'
          >>> print test.__class__
          <class 'cli.CLIPluginFuncWrapper'>
  
          >>> @cli_plugin(help='dummy help')
          ... def test(**kwargs):
          ...     print 'test'
          >>> print test.__class__
          <class 'cli.CLIPluginFuncWrapper'>
          >>> print test.init_args['help']
          'dummy help'
  
      """
      # this allows calling this function as a decorator generator
      if func is None:
          return functools.partial(cli_plugin, **kwargs)
  
      if not isinstance(func, CLIPluginFuncWrapper):
          func = CLIPluginFuncWrapper(do_run=func, init_args=kwargs)
      else:
          func.set_init_args(kwargs)
  
      return func