aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLars Ingebrigtsen2019-10-13 00:22:03 +0200
committerLars Ingebrigtsen2019-10-13 00:22:37 +0200
commit5fffed6e88644cdf0a1d9fdaf728e75336e39ecd (patch)
tree343a975be725e91c3ce06306b749eb0902edd66f
parent914b98a1c690874382a31a4f3c27bda517dcd48b (diff)
downloademacs-5fffed6e88644cdf0a1d9fdaf728e75336e39ecd.tar.gz
emacs-5fffed6e88644cdf0a1d9fdaf728e75336e39ecd.zip
Document locate-dominating-file
* doc/lispref/files.texi (Contents of Directories): Document locate-dominating-file (bug#33869).
-rw-r--r--doc/lispref/files.texi14
1 files changed, 14 insertions, 0 deletions
diff --git a/doc/lispref/files.texi b/doc/lispref/files.texi
index 3746c6d2c95..130282c582d 100644
--- a/doc/lispref/files.texi
+++ b/doc/lispref/files.texi
@@ -2924,6 +2924,7 @@ that can be read.
2924@end defun 2924@end defun
2925 2925
2926@defun directory-files-recursively directory regexp &optional include-directories predicate follow-symlinks 2926@defun directory-files-recursively directory regexp &optional include-directories predicate follow-symlinks
2927@cindex recursing downwards in directories
2927Return all files under @var{directory} whose names match @var{regexp}. 2928Return all files under @var{directory} whose names match @var{regexp}.
2928This function searches the specified @var{directory} and its 2929This function searches the specified @var{directory} and its
2929sub-directories, recursively, for files whose basenames (i.e., without 2930sub-directories, recursively, for files whose basenames (i.e., without
@@ -2949,6 +2950,19 @@ Symbolic links to subdirectories are not followed by default, but if
2949@var{follow-symlinks} is non-@code{nil}, they are followed. 2950@var{follow-symlinks} is non-@code{nil}, they are followed.
2950@end defun 2951@end defun
2951 2952
2953@defun locate-dominating-file file name
2954@cindex recursing upwards in directories
2955Starting at @var{file}, recurse up the directory hierarchy looking for
2956the first directory where @var{name} exists, which is then the return
2957value of this function. @var{file} can be a file or a directory. If
2958it's a file, its directory will serve as the starting point for
2959searching the hierarchy of directories.
2960
2961@code{name} can be either a string or a predicate. The predicate
2962takes one argument (the directory) and should return non-@code{nil} if
2963we've found the directory we're looking for.
2964@end defun
2965
2952@defun directory-files-and-attributes directory &optional full-name match-regexp nosort id-format 2966@defun directory-files-and-attributes directory &optional full-name match-regexp nosort id-format
2953This is similar to @code{directory-files} in deciding which files 2967This is similar to @code{directory-files} in deciding which files
2954to report on and how to report their names. However, instead 2968to report on and how to report their names. However, instead