package opam-client
Install
Dune Dependency
Authors
-
VVincent Bernardoff <vb@luminar.eu.org>
-
RRaja Boujbel <raja.boujbel@ocamlpro.com>
-
RRoberto Di Cosmo <roberto@dicosmo.org>
-
TThomas Gazagnaire <thomas@gazagnaire.org>
-
LLouis Gesbert <louis.gesbert@ocamlpro.com>
-
FFabrice Le Fessant <Fabrice.Le_fessant@inria.fr>
-
AAnil Madhavapeddy <anil@recoil.org>
-
GGuillem Rieu <guillem.rieu@ocamlpro.com>
-
RRalf Treinen <ralf.treinen@pps.jussieu.fr>
-
FFrederic Tuong <tuong@users.gforge.inria.fr>
Maintainers
Sources
md5=1e55c234fa09e678e8115a31f3ec2a05
sha512=d71c362d70a6b6cb9fe54cc43bfbea8079cca05d4721a7dda951196f543a1ff5af81399a246e0cd68bc590c7bdca388d96c7127217ed637261957047ce725516
doc/opam-client/OpamPinCommand/index.html
Module OpamPinCommand
Source
Functions handling the "opam pin" subcommand
val version_pin :
OpamStateTypes.rw OpamStateTypes.switch_state ->
OpamTypes.name ->
OpamTypes.version ->
OpamStateTypes.rw OpamStateTypes.switch_state
Pins a package to the given version, and writes to disk. Returns the updated state. The main difference with source_pin
is that a definition overlay is not created. Therefore, the package must exist already.
val source_pin :
OpamStateTypes.rw OpamStateTypes.switch_state ->
OpamTypes.name ->
?version:OpamTypes.version ->
?edit:bool ->
?opam:OpamFile.OPAM.t ->
?quiet:bool ->
?force:bool ->
?ignore_extra_pins:bool ->
OpamTypes.url option ->
OpamStateTypes.rw OpamStateTypes.switch_state
Sets the package as pinned to the given target. A package definition is looked for in the package source and current metadata (in this order), unless specified using ~opam
.
If edit
, or if no package definition is found, this opens an editor (with a template if no definition is available).
If force
, don't abort even if the source can't be fetched from target
May raise Aborted
or Nothing_to_do
.
val handle_pin_depends :
OpamStateTypes.rw OpamStateTypes.switch_state ->
OpamTypes.package ->
OpamFile.OPAM.t ->
OpamStateTypes.rw OpamStateTypes.switch_state
Interactively handles the pin-depends
in an opam file
val edit :
OpamStateTypes.rw OpamStateTypes.switch_state ->
?version:OpamTypes.version ->
OpamTypes.name ->
OpamStateTypes.rw OpamStateTypes.switch_state
Let the user edit a pinned package's opam file. If given, the version is put into the template in advance. Writes and returns the updated switch state.
val unpin :
OpamStateTypes.rw OpamStateTypes.switch_state ->
OpamTypes.name list ->
OpamStateTypes.rw OpamStateTypes.switch_state
Unpin packages
val unpin_one :
'a OpamStateTypes.switch_state ->
OpamTypes.package ->
'a OpamStateTypes.switch_state
Pure function that reverts a single package pinning
List the pinned packages to the user.
val read_opam_file_for_pinning :
?quiet:bool ->
OpamTypes.name ->
OpamFile.OPAM.t OpamFile.t ->
OpamTypes.url ->
OpamFile.OPAM.t option
Lints the given opam file, prints warnings or errors accordingly (unless quiet
), upgrades it to current format, adds references to files below the 'files/' subdir (unless the file is directly below the specified, local url
), and returns it
The default version for pinning a package: depends on the state, what is installed and available, and defaults to ~dev
.