package ocaml-xdg-basedir
xdg-basedir specification implementation
Install
Dune Dependency
Authors
Maintainers
Sources
ocaml-xdg-basedir-0.0.3.tar.gz
sha256=0b2bdead251d686fee43e478c2aebb84a8e4af90011bdc8bd29870b37dcd66b3
md5=68367eba73f6094fea8c6ffee0072e20
doc/xdg-basedir/XDGBaseDir/index.html
Module XDGBaseDir
XDG basedir implementation
The XDG basedir specification makes clear where to store configuration, cache and data files. This a way to maintain a clean $HOME. Locations can be customized through environment variables (XDG_DATA_HOME, XDG_CONFIG_HOME). It also allows to store files in several places (i.e. system directories).
Types
type dirnames = dirname list
type t = {
data_home : dirname;
(*$HOME/.local/share
*)data_dirs : dirnames;
(*/usr/share
*)config_home : dirname;
(*$HOME/.config
*)config_dirs : dirnames;
(*/etc/xdg
*)cache_home : dirname;
(*$HOME/.cache
*)
}
XDG environment
Modules and functions
val default : t
Default XDG environment
mkdir_openfile f fn
Create parent directory of fn
and apply f fn
module Data : sig ... end
In this module, ~xdg_env
allows to override the default XDG environment. If you use ~exists:true
, the files/dirs are tested for existence.
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>
On This Page