community / community.general / 1.3.11 / module / homebrew Package manager for Homebrew Authors: Indrajit Raychaudhuri (@indrajitr), Daniel Jaouen (@danieljaouen), Andrew Dunham (@andrew-d)community.general.homebrew (1.3.11) — module
Install with ansible-galaxy collection install community.general:==1.3.11
collections: - name: community.general version: 1.3.11
Manages Homebrew packages
# Install formula foo with 'brew' in default path - community.general.homebrew: name: foo state: present
# Install formula foo with 'brew' in alternate path C(/my/other/location/bin) - community.general.homebrew: name: foo path: /my/other/location/bin state: present
# Update homebrew first and install formula foo with 'brew' in default path - community.general.homebrew: name: foo state: present update_homebrew: yes
# Update homebrew first and upgrade formula foo to latest available with 'brew' in default path - community.general.homebrew: name: foo state: latest update_homebrew: yes
# Update homebrew and upgrade all packages - community.general.homebrew: update_homebrew: yes upgrade_all: yes
# Miscellaneous other examples - community.general.homebrew: name: foo state: head
- community.general.homebrew: name: foo state: linked
- community.general.homebrew: name: foo state: absent
- community.general.homebrew: name: foo,bar state: absent
- community.general.homebrew: name: foo state: present install_options: with-baz,enable-debug
- name: Use ignored-pinned option while upgrading all community.general.homebrew: upgrade_all: yes upgrade_options: ignored-pinned
name: aliases: - formula - package - pkg description: - A list of names of packages to install/remove. elements: str type: list path: default: /usr/local/bin:/opt/homebrew/bin description: - A ':' separated list of paths to search for 'brew' executable. Since a package (I(formula) in homebrew parlance) location is prefixed relative to the actual path of I(brew) command, providing an alternative I(brew) path enables managing different set of packages in an alternative location in the system. type: path state: choices: - absent - head - installed - latest - linked - present - removed - uninstalled - unlinked - upgraded default: present description: - state of the package. type: str upgrade_all: aliases: - upgrade default: false description: - upgrade all homebrew packages. type: bool install_options: aliases: - options description: - options flags to install a package. elements: str type: list update_homebrew: aliases: - update-brew default: false description: - update homebrew itself first. type: bool upgrade_options: description: - Option flags to upgrade. elements: str type: list version_added: 0.2.0 version_added_collection: community.general
changed_pkgs: description: - List of package names which are changed after module run returned: success sample: - git - git-cola type: list version_added: 0.2.0 version_added_collection: community.general msg: description: if the cache was updated or not returned: always sample: 'Changed: 0, Unchanged: 2' type: str unchanged_pkgs: description: - List of package names which are unchanged after module run returned: success sample: - awscli - ag type: list version_added: 0.2.0 version_added_collection: community.general