opam-core

Core library for opam 2.1
IN THIS PACKAGE
Module OpamVersion
include OpamStd.ABSTRACT
type t
val of_string : string -> t
val to_string : t -> string
val to_json : t -> OpamJson.t
val of_json : OpamJson.t -> t option
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 is_dev_version : unit -> bool

true if this is a development version of opam

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