def METHOD_NAME(name, gid):
    """
    Change the gid for a named group
    CLI Example:
    .. code-block:: bash
        salt '*' group.chgid foo 4376
    """
    pre_gid = __salt__["file.group_to_gid"](name)
    if gid == pre_gid:
        return True
    cmd = "pw groupmod {} -g {}".format(name, gid)
    __salt__["cmd.run"](cmd, python_shell=False)
    post_gid = __salt__["file.group_to_gid"](name)
    if post_gid != pre_gid:
        return post_gid == gid
    return False