A decorator that transforms a function into a :class:`.Group`.

    This is similar to the :func:`.command` decorator but the ``cls``
    parameter is set to :class:`Group` by default.

    .. versionchanged:: 1.1.0
        The ``cls`` parameter can now be passed.

def group(name=None, **attrs):
    """A decorator that transforms a function into a :class:`.Group`.

    This is similar to the :func:`.command` decorator but the ``cls``
    parameter is set to :class:`Group` by default.

    .. versionchanged:: 1.1.0
        The ``cls`` parameter can now be passed.
    """

    attrs.setdefault('cls', Group)
    return command(name=name, **attrs)