Skip to content

Refactor Dependencies into separate files

Gabriel Mazetto requested to merge brodock/refactor-dependencies into main

What does this Merge Request do and why?

Dependencies are already exposed into separate classes, but they all live in the same dependencies.rb.

This change split them into their own file, add spec coverage to untested content and rewrite some small parts.

This also changes how we detect Homebrew, MacPorts and APT, so we rely on them being available in PATH instead of fixed locations. This is important because in case of Homebrew, there are two different locations it can be in MacOS depending whether it is Intel or ARM.

In case of Homebrew on Linux is also can live in either system or user home location.

Merge Request checklist

  • This change is backward compatible. If not, please include steps to communicate to our users.
  • Tests added for new functionality. If not, please raise Issue to follow-up.
  • Documentation added/updated, if needed.
  • gdk doctor test added, if needed.
  • Add the ~highlight label if this MR should be included in the CHANGELOG.md.
Edited by Gabriel Mazetto

Merge request reports