Module Cmdliner_info.Arg

Arguments

type absence =
  1. | Err
    (*

    an error is reported.

    *)
  2. | Val of string Stdlib.Lazy.t
    (*

    if <> "", takes the given default value.

    *)
  3. | Doc of string
    (*

    if <> "", a doc string interpreted in the doc markup language.

    *)

The type for what happens if the argument is absent from the cli.

type opt_kind =
  1. | Flag
    (*

    without value, just a flag.

    *)
  2. | Opt
    (*

    with required value.

    *)
  3. | Opt_vopt of string
    (*

    with optional value, takes given default.

    *)

The type for optional argument kinds.

type pos_kind
val pos : rev:bool -> start:int -> len:int option -> pos_kind
val pos_rev : pos_kind -> bool
val pos_start : pos_kind -> int
val pos_len : pos_kind -> int option
type t
val v : ?deprecated:string -> ?absent:string -> ?docs:string -> ?docv:string -> ?doc:string -> ?env:Env.info -> string list -> t
val id : t -> int
val deprecated : t -> string option
val absent : t -> absence
val env : t -> Env.info option
val doc : t -> string
val docv : t -> string
val docs : t -> string
val opt_names : t -> string list
val opt_name_sample : t -> string
val opt_kind : t -> opt_kind
val pos_kind : t -> pos_kind
val make_req : t -> t
val make_all_opts : t -> t
val make_opt : absent:absence -> kind:opt_kind -> t -> t
val make_opt_all : absent:absence -> kind:opt_kind -> t -> t
val make_pos : pos:pos_kind -> t -> t
val make_pos_abs : absent:absence -> pos:pos_kind -> t -> t
val is_opt : t -> bool
val is_pos : t -> bool
val is_req : t -> bool
val pos_cli_order : t -> t -> int
val rev_pos_cli_order : t -> t -> int
val compare : t -> t -> int
module Set : Stdlib.Set.S with type elt = t