diff options
author | Eli Zaretskii <eliz@gnu.org> | 2022-10-08 14:13:50 +0300 |
---|---|---|
committer | Eli Zaretskii <eliz@gnu.org> | 2022-10-08 14:13:50 +0300 |
commit | 32ef7550edc887f1f8e052cb57a61c4e82b6eecd (patch) | |
tree | fe0b4feaf77b1ad852ac02f9003c4ef1a175e796 /doc/lispref/files.texi | |
parent | cfb1e218447c796f7a48347f648152b30f3edf92 (diff) | |
download | emacs-32ef7550edc887f1f8e052cb57a61c4e82b6eecd.tar.gz emacs-32ef7550edc887f1f8e052cb57a61c4e82b6eecd.tar.bz2 emacs-32ef7550edc887f1f8e052cb57a61c4e82b6eecd.zip |
; Improve documentation of 'file-in-directory-p'
* lisp/files.el (file-in-directory-p): Clarify doc string.
* doc/lispref/files.texi (Truenames): Move the documentation of
'file-in-directory-p' from here...
(Contents of Directories): ...to here. Add index entries.
(Bug#58364)
Diffstat (limited to 'doc/lispref/files.texi')
-rw-r--r-- | doc/lispref/files.texi | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/doc/lispref/files.texi b/doc/lispref/files.texi index 08677f789a5..32a862b5825 100644 --- a/doc/lispref/files.texi +++ b/doc/lispref/files.texi @@ -1250,14 +1250,6 @@ the @samp{smb} method. For all other connection methods, runtime tests are performed. @end defun -@defun file-in-directory-p file dir -This function returns @code{t} if @var{file} is a file in directory -@var{dir}, or in a subdirectory of @var{dir}. It also returns -@code{t} if @var{file} and @var{dir} are the same directory. It -compares the truenames of the two directories. If @var{dir} does not -name an existing directory, the return value is @code{nil}. -@end defun - @defun vc-responsible-backend file This function determines the responsible VC backend of the given @var{file}. For example, if @file{emacs.c} is a file tracked by Git, @@ -3052,6 +3044,17 @@ is called with one argument (the file or directory) and should return non-@code{nil} if that directory is the one it is looking for. @end defun +@cindex parent directory of file +@cindex ancestor directory of file +@cindex file, ancestor directory of +@defun file-in-directory-p file dir +This function returns @code{t} if @var{file} is a file in directory +@var{dir}, or in a subdirectory of @var{dir}. It also returns +@code{t} if @var{file} and @var{dir} are the same directory. It +compares the truenames of the two directories. If @var{dir} does not +name an existing directory, the return value is @code{nil}. +@end defun + @defun directory-files-and-attributes directory &optional full-name match-regexp nosort id-format count This is similar to @code{directory-files} in deciding which files to report on and how to report their names. However, instead |