package rpmfile

  1. Overview
  2. Docs

RPM package metadata reader.

type lead = Lead.t
type header = (int * Header.index_value) list
type metadata = Types.metadata = {
  1. lead : lead;
  2. signature : header;
  3. header : header;
}
module P (_ : Selector.S) : sig ... end

Angstrom parsers.

module Reader (_ : Selector.S) : sig ... end

Standard reader with poor performance for reading from string or file.

module Selector : sig ... end

Predicate for parsing only necessary tags.

module Types : sig ... end
module Tag : sig ... end
module D : sig ... end

value type's decoders.

module Header : sig ... end

Representation of Header and Signature sections.

module Lead : sig ... end

Representation of Lead section.

exception Not_found of string
exception Decode_error of string
val get_value : 'a -> ('a * 'b) list -> 'b

Help function for getting value from assoc list.

val get : ?msg:string -> 'a D.decoder -> int -> metadata -> 'a

get ?msg decoder tag metadata to find value by tag and decoder it.

val get_opt : 'a D.decoder -> int -> metadata -> 'a option

Similar to get function, but returns an optional type instead of exceptions if the tag is not found.

val get_from_signature : ?msg:string -> 'a D.decoder -> int -> metadata -> 'a

Similar to get function, but for Signature section.

val get_opt_from_signature : 'a D.decoder -> int -> metadata -> 'a option
val name : metadata -> string
val summary' : metadata -> string list
val summary : metadata -> string
val description' : metadata -> string list
val description : metadata -> string
val build_time : metadata -> int
  • returns

    Unix-time.

val build_host : metadata -> string
val size : metadata -> int

Sum of the sizes of the regular files in the archive.

val os : metadata -> string
val license : metadata -> string
val vendor : metadata -> string
val version : metadata -> string
val release : metadata -> string
val packager : metadata -> string
val distribution : metadata -> string
val group : metadata -> string list
val url : metadata -> string
val dist_url : metadata -> string
val arch : metadata -> string
val archive_size : metadata -> int option
val md5 : metadata -> Bigstringaf.t option
val sha1 : metadata -> Bigstringaf.t
val payload_size : metadata -> int
val payload_format : metadata -> string
val payload_compressor : metadata -> string
val payload_flags : metadata -> string
val source_rpm : metadata -> string
val filenames : metadata -> string list
val platform : metadata -> string
val provide_names : metadata -> string list
val require_names : metadata -> string list
OCaml

Innovation. Community. Security.