package git

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

Module Value.CommitSource

Sourcetype t

A Git Commit object. Which specifies the top-level Tree.t for the snapshot of the project at a point; the author/committer information and the commit message.

Sourceval make : tree:H.t -> author:User.t -> committer:User.t -> ?parents:H.t list -> ?extra:(string * string list) list -> string -> t

make ~author ~committer ?parents ~tree msg makes an OCaml value t. ?parents should be a non-empty list and corresponds to a list of hashes of commits. tree should be a hash of a Tree.t object.

This function does not write a new commit on the store and does not check the validity of parents and tree. By this way, this function never fails.

Sourcemodule MakeMeta (Meta : Encore.Meta.S) : sig ... end
Sourcemodule A : sig ... end
Sourcemodule M : sig ... end
Sourcemodule D : sig ... end
Sourcemodule E : sig ... end
Sourceval digest : t -> H.t
Sourceval pp : t Fmt.t
Sourceval compare : t -> t -> int
Sourceval hash : t -> int
Sourceval equal : t -> t -> bool
Sourcemodule Set : Set.S with type elt = t
Sourcemodule Map : Map.S with type key = t
Sourceval length : t -> int64

length t returns the length of the commit object t.

Sourceval parents : t -> H.t list

parents c returns all parents of the Git Commit object c.

Sourceval tree : t -> H.t

tree c returns the hash of top-level Tree.t of the Git Commit object c.

Sourceval committer : t -> User.t

committer c returns the committer of the commit c.

Sourceval author : t -> User.t

author c returns the author of the commit c.

Sourceval message : t -> string

message c returns the message of the commit c.

Sourceval extra : t -> (string * string list) list
Sourceval compare_by_date : t -> t -> int

compare_by_date a b compares the Git Commit object a and b by the date of the author. The compare function as the same behaviour.

OCaml

Innovation. Community. Security.