|
Flox Package Database 1
CRUD Operations on Nix Package Metadata
|
A set of user defined requirements describing a package/dependency. More...
#include <descriptor.hh>
Public Member Functions | |
| ManifestDescriptor (const std::string_view &descriptor) | |
| ManifestDescriptor (const ManifestDescriptorRaw &raw) | |
| ManifestDescriptor (std::string_view installID, const ManifestDescriptorRaw &raw) | |
| void | check () const |
Ensure that a descriptor has at least name, path, or absPath fields. Throws an exception if the descriptor is invalid. | |
| void | clear () |
| Reset to default state. | |
| pkgdb::PkgQueryArgs & | fillPkgQueryArgs (pkgdb::PkgQueryArgs &pqa) const |
| Fill a flox::pkgdb::PkgQueryArgs struct with preferences to lookup packages. | |
Public Attributes | |
| std::optional< std::string > | name |
| bool | optional = false |
| std::optional< GroupName > | group |
| std::optional< std::string > | version |
| std::optional< std::string > | semver |
| std::optional< Subtree > | subtree |
| std::optional< std::vector< System > > | systems |
| std::optional< flox::AttrPath > | path |
| std::optional< nix::FlakeRef > | input |
| unsigned | priority = 5 |
A set of user defined requirements describing a package/dependency.
May either be defined as a set of attributes or with a string matching this syntax: [<input>:]((<attr>.)+<attrName>)|(<pname>|<attrName>|<name>)[@(<semver>|=<version>)]
| pkgdb::PkgQueryArgs & flox::resolver::ManifestDescriptor::fillPkgQueryArgs | ( | pkgdb::PkgQueryArgs & | pqa | ) | const |
Fill a flox::pkgdb::PkgQueryArgs struct with preferences to lookup packages.
NOTE: This DOES NOT clear pqa before filling it. This is intended to be used after filling pqa with global preferences.
| pqa | A set of query args to fill with preferences. |
| std::optional<GroupName> flox::resolver::ManifestDescriptor::group |
Named group that the package is a member of.
| std::optional<nix::FlakeRef> flox::resolver::ManifestDescriptor::input |
Force resolution in a given input, flake reference.
| std::optional<std::string> flox::resolver::ManifestDescriptor::name |
Match name, pname, or attrName
| bool flox::resolver::ManifestDescriptor::optional = false |
Whether resolution is allowed to fail without producing errors.
| std::optional<flox::AttrPath> flox::resolver::ManifestDescriptor::path |
Match a relative attribute path.
| unsigned flox::resolver::ManifestDescriptor::priority = 5 |
Rank a package's priority for handling conflicting files. The default value is 5 ( set in flox::resolver::ManifestDescriptor ).
Packages with higher priority values will take precendence over those with lower priority values.
| std::optional<std::string> flox::resolver::ManifestDescriptor::semver |
Match a semantic version range.
| std::optional<Subtree> flox::resolver::ManifestDescriptor::subtree |
Match a subtree.
| std::optional<std::vector<System> > flox::resolver::ManifestDescriptor::systems |
Only resolve for a given set of systems.
| std::optional<std::string> flox::resolver::ManifestDescriptor::version |
Match version.