B0_metaSourceMetadata.
Typed key-value dictionaries. Values of this type are used with various B0 definitions to specify metadata.
The module defines a few standard keys. The recommended way of formatting constant dictionaries is:
let meta =
let open B0_meta in (* This can be omitted *)
empty
|> add authors ["The project programmers"]
|> add homepage "https://example.org"
|> tag B0_opam.Meta.tagXXX. They used to be serializable, see if we don't want that again.
The type for keys whose lookup value is of type 'a.
pp_binding formats a binding using B0_std.Fmt.field and the key's value print function.
The type for metadata.
add_if_some k o m is m if o is None and m with k bound to v if o is Some v.
find_binding k m is the binding for k in m (if any).
find_binding_by_name n m is the binding named n in m (if any).
get k m is the binding of k in m. Raises Invalid_argument if there is no such binding.
find_binding k m is the binding for k in m. Raises Invalid_argument if there is no such binding.
get_binding_by_name n m is the binding named n in m. Raises Invalid_argument if there is no such binding.
fold f m acc folds f over the bindings of m starting with acc.
pp formats metadata using pp_bindings.
pp_non_empty is Fmt.cut followed by pp if metadata is non empty and Fmt.nop otherwise.
description_tags describes a list of classification tags used for documentation.
licenses describes a list of licenses. Each license should be a SPDX license identifier.
exe_name is an executable name without the platform specific executable extension. FIXME rename that to tool.
exe_file is an absolute file path to an executable build by the unit.