package ecaml

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

File is for functions that operate on files on the filesystem.

(Info-goto-node "(elisp)Information about Files")

val exists : string -> bool

(describe-function 'file-exists-p)

val is_directory : string -> bool

(describe-function 'file-directory-p)

val is_executable : string -> bool

(describe-function 'file-executable-p)

val is_readable : string -> bool

(describe-function 'file-readable-p)

val is_regular : string -> bool

(describe-function 'file-regular-p)

(describe-function 'file-symlink-p)

val is_writable : string -> bool

(describe-function 'file-writable-p)

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_value.Value.t -> filename:string -> path:string list -> unit -> string option

(describe-function 'locate-file)

val locate_dominating_file : above:Filename.t -> basename:string -> Filename.t option

(describe-function 'locate-dominating-file)

val locate_dominating_file_exn : above:Filename.t -> basename:string -> Filename.t

(describe-function 'locate-dominating-file)

val write : ?append:bool -> Filename.t -> string -> unit

(describe-function 'write-region) (Info-goto-node "(elisp)Writing to Files")

val ensure_exists : Filename.t -> unit
val make_temp_file : prefix:string -> suffix:string -> Filename.t

(describe-function 'make-temp-file) (Info-goto-node "(elisp)Unique File Names")

val with_temp_file : (_, 'a) Sync_or_async.t -> f:(Filename.t -> 'a) -> prefix:string -> suffix:string -> 'a

Creates a temp file, calls f on its name, and deletes it after f returns, even if f returns by raising.

N.B. This is not the behavior of (describe-function 'with-temp-file).

val find_executable : string -> string option

(describe-function 'executable-find)

OCaml

Innovation. Community. Security.