package current_gitlab

  1. Overview
  2. Docs

Module Current_gitlab.ApiSource

Access to the GitLab API.

Sourcetype t

Configuration for accessing GitLab.

Sourceval webhook_secret : t -> string

Webhook secret to validate payloads from GitLab.

Sourcetype refs

Reference information for the Repository.

Sourcemodule Status : sig ... end

Status associated with a single Commit.t.

Sourcemodule Commit : sig ... end

A specific Git commit.

Sourcemodule Repo : sig ... end

A Project's repository on GitLab.

Sourcemodule Ref : sig ... end

A Ref as an indirect way of referring to a commit.

Sourcemodule Ref_map : Map.S with type key = Ref.t
Sourceval head_commit : t -> Repo_id.t -> Commit.t Current.t

head_commit t repo evaluates to the commit at the head of the default branch in repo.

Sourceval ci_refs : ?staleness:Duration.t -> t -> Repo_id.t -> Commit.t list Current.t

ci_refs t repo evaluates to the list of branches and open PRs in repo.

  • parameter staleness

    If given, commits older than this are excluded. Note: the main branch commit is always included, even if stale.

refs t repo is the primitive for all the references in repo. This is the low-level API for getting the refs. It is used internally by ci_refs and head_of but in some cases you may want to use it directly, default_ref and all_refs will expose useful information for you. The result is cached (so calling it twice will return the same primitive).

Sourceval default_ref : refs -> Ref.t

default_ref refs will return the full name of the repository's default branch ref

Sourceval all_refs : refs -> Commit.t Ref_map.t

all_refs refs will return a map of all the repository's refs

Sourcemodule Anonymous : sig ... end

Perform Anonymous request to GitLab.

Sourceval cmdliner : t Cmdliner.Term.t

Command-line options to generate a GitLab configuration.

OCaml

Innovation. Community. Security.