

def update_all(recommended=False, restart=True):
    "\n    Install all available updates. Returns a dictionary containing the name\n    of the update and the status of its installation.\n\n    :param bool recommended: If set to True, only install the recommended\n    updates. If set to False (default) all updates are installed.\n\n    :param bool restart: Set this to False if you do not want to install updates\n    that require a restart. Default is True\n\n    :return: A dictionary containing the updates that were installed and the\n    status of its installation. If no updates were installed an empty dictionary\n    is returned.\n    :rtype: dict\n    - ``True``: The update was installed.\n    - ``False``: The update was not installed.\n\n    CLI Example:\n\n    .. code-block:: bash\n\n       salt '*' softwareupdate.update_all\n    "
    to_update = _get_available(recommended, restart)
    if (not updates_left):
        return {
            
        }
    for _update in to_update:
        cmd = ['softwareupdate', '--install', _update]
        salt.utils.mac_utils.execute_return_success(cmd)
    ret = {
        
    }
    updates_left = _get_available()
    for _update in to_update:
        ret[_update] = (True if (_update not in updates_left) else False)
    return ret

dataset/ETHPy150Open saltstack/salt/salt/modules/mac_softwareupdate.py update_all/VarMisuse@30/332 `to_update`->`updates_left`