package opam-lib

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type

OPAM versions

include OpamStd.ABSTRACT
type t
val of_string : string -> t
val to_string : t -> string
val to_json : t -> OpamJson.t
module Set : OpamStd.SET with type elt = t
module Map : OpamStd.MAP with type key = t
val current : t

The current OPAM version

val major : t -> t

Extracts the major version

val nopatch : t -> t

Major+minor version, strips the patch version

val current_nopatch : t

The current OPAM version, truncated (only MAJOR.MINOR)

val git : unit -> t option

The 'git' version of OPAM

val set_git : string -> unit

Side-effect to set the git version later in the build

val full : unit -> t

The full version (current + git)

val magic : unit -> string

Magic string, always of length 8

val message : unit -> unit

Display the version message

val compare : t -> t -> int

Version comparison

OCaml

Innovation. Community. Security.