package opam-core
Install
dune-project
Dependency
Authors
-
David Allsopp
-
VVincent Bernardoff <vb@luminar.eu.org>
-
RRaja Boujbel <raja.boujbel@ocamlpro.com>
-
KKate Deplaix <kit-ty-kate@outlook.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=fc3e769ecf6acee13e249d6d1ab52b60
sha512=b57536f4530ed03c8f3cc8cf814af9a2c53b159f58fc1b50be93295f6eb8d53faeef3d916e1a3f5137d35468af15fc2f59a2f8bda5c574532ab523fd945b9781
doc/opam-core/OpamUrl/index.html
Module OpamUrlSource
URL parsing and printing, with support for our different backends
Same as of_string, but allows enforcing the expected backend, and may otherwise guess version control from the suffix by default (for e.g. https://foo/bar.git). (this should be disabled when parsing from files). Note that handle_suffix also handles user-name in ssh addresses (e.g. "ssh://git@github.com/..."). If from_file is set to false, it resolves rsync/file relative path.
val parse_opt :
?quiet:bool ->
?backend:backend ->
?handle_suffix:bool ->
?from_file:bool ->
string ->
t optionSame as parse, but catch Parse_error. In this case, display a warning if quiet is not set to true.
Returns the url string without the VC part (i.e. "git+foo://bar" returns "foo://bar")
The last part of the url path, e.g. "http://foo/bar/this" or "http://that.here/"
Returns the url with all path components but the first one (the hostname) dropped, e.g. "http://some.host/some/path" becomes "http://some.host"
Check if the URL matches an existing local directory, and return it
Check if the URL matches an existing local file, and return it
If the given url-string has no 'transport://' specification and corresponds to an existing local path, check for version-control clues at that path
map_file_url f url applies f to the path portion of url if transport is "file".