SubconsciousCompute / meta-package-manager

A meta package manager for interfacing with multiple distro/platform specific package managers.
GNU Affero General Public License v3.0
3 stars 2 forks source link

Type based verification: wrappers and trait #3

Closed VoltaireNoir closed 1 year ago

VoltaireNoir commented 1 year ago

This introduces a module for simple type-based verification checks using two kinds of wrapper types:

These signify that a package manager is installed and is safe to interact with. The constructors of these types internally use is_installed function provided in this module. The private internal fields ensure that they cannot be constructed directly without calling the provided new constructors.

A Verify trait is also included, which provides constructors directly on all T that implement PackageManager.

This module is placed behind a feature gate: verify