Module Ecaml.File
File
is for functions that operate on files on the filesystem.
val is_below : string -> dir:string -> bool
(describe-function 'file-in-directory-p)
(Info-goto-node "(elisp)Truenames")
val truename : string -> string
(describe-function 'file-truename)
(Info-goto-node "(elisp)Truenames")
val delete : string -> unit
(describe-function 'delete-file)
(Info-goto-node "(elisp)Changing Files")
val copy : src:string -> dst:string -> unit
(describe-function 'copy-file)
(Info-goto-node "(elisp)Changing Files")
val rename : src:string -> dst:string -> replace_dst_if_exists:bool -> unit
(describe-function 'rename-file)
(Info-goto-node "(elisp)Changing Files")
val locate : ?suffixes:string list -> ?predicate:Ecaml__.Import.Value.t -> filename:string -> path:string list -> unit -> string option
(describe-function 'locate-file)
val locate_dominating_file : above:Ecaml__.Ecaml_filename.Filename.t -> basename:string -> Ecaml__.Ecaml_filename.Filename.t option
(describe-function 'locate-dominating-file)
val locate_dominating_file_exn : above:Ecaml__.Ecaml_filename.Filename.t -> basename:string -> Ecaml__.Ecaml_filename.Filename.t
(describe-function 'locate-dominating-file)
val write : ?append:bool -> Ecaml__.Ecaml_filename.Filename.t -> string -> unit
(describe-function 'write-region)
(Info-goto-node "(elisp)Writing to Files")
val ensure_exists : Ecaml__.Ecaml_filename.Filename.t -> unit
val make_temp_file : prefix:string -> suffix:string -> Ecaml__.Ecaml_filename.Filename.t
(describe-function 'make-temp-file)
(Info-goto-node "(elisp)Unique File Names")
val with_temp_file : (_, 'a) Sync_or_async.t -> f:(Ecaml__.Ecaml_filename.Filename.t -> 'a) -> prefix:string -> suffix:string -> 'a
Creates a temp file, calls
f
on its name, and deletes it afterf
returns, even iff
returns by raising.N.B. This is not the behavior of
(describe-function 'with-temp-file)
.