package xdg

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

Module XdgSource

Sourcetype t

Base directories. Values of type t are created using create.

Sourceval home_dir : t -> string

The user's home directory. Uses $USERPROFILE on Windows, $HOME otherwise.

Sourceval config_dir : t -> string

The directory where the application should read/write config files.

Sourceval data_dir : t -> string

The directory where the application should read/write data files.

Sourceval cache_dir : t -> string

The directory where the application should read/write cached files.

Sourceval state_dir : t -> string

The directory where the application should read/write state files.

Sourceval runtime_dir : t -> string option

The directory where the application should store socket files.

Sourceval create : ?win32:bool -> env:(string -> string option) -> unit -> t

Constructor of type t. ~win32 (default: Sys.win32) determines whether to use Win32-specific APIs. ~env is the function to get environment variables, typically Sys.getenv_opt.

OCaml

Innovation. Community. Security.