mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-22 12:50:22 -07:00
Greatly speed up homebrew module when multiple packages are passed in the name
key (#9181)
* Increase test coverage and assert output more strictly * Remove unused `_current_package_is_installed_from_head` * Remove `un/changed_count` and infer from un/changed_pkgs length * Track `installed` & `outdated` package state once * Validate package names beforehand * Install packages in 1 brew call instead of N This also has the side effect of fixing the check message so that it prints every packages that will be installed instead of only the first one. * Uninstall packages in 1 brew call instead of N * Link packages in 1 brew call instead of N * Unlink packages in 1 brew call instead of N * Upgrade packages in 1 brew call instead of N * Remove dangling checks * Remove `_status` method and directly return the tuple * Add changelog fragment * Fix invalid format string (nice catch pylint!) * Update changelogs/fragments/9181-improve-homebrew-module-performance.yml Co-authored-by: Felix Fontein <felix@fontein.de> * Update brew info parsing for casks * Update changelogs/fragments/9181-improve-homebrew-module-performance.yml Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com> --------- Co-authored-by: Felix Fontein <felix@fontein.de> Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
This commit is contained in:
parent
da97e220ef
commit
fddccea940
3 changed files with 409 additions and 191 deletions
|
@ -0,0 +1,2 @@
|
|||
minor_changes:
|
||||
- homebrew - greatly speed up module when multiple packages are passed in the ``name`` option (https://github.com/ansible-collections/community.general/pull/9181).
|
Loading…
Add table
Add a link
Reference in a new issue