def commands():
    """ Return a list of command name and description tuples. """
    cmds = []
    for key in sorted(globals().keys()):
        if key.startswith('git_gerrit_'):
            name = key.replace('git_gerrit_', 'git gerrit-').replace('_', '-')
            desc = globals()[key].__doc__.strip().strip()
            cmds.append((name, desc))
    return cmds
