]> git.eshelyaron.com Git - emacs.git/commit
make-directory now returns t if dir already exists
authorPaul Eggert <eggert@cs.ucla.edu>
Sat, 17 Dec 2022 20:15:30 +0000 (12:15 -0800)
committerPaul Eggert <eggert@cs.ucla.edu>
Sat, 17 Dec 2022 22:24:16 +0000 (14:24 -0800)
commitbef1edc9cacb976120dff73b4d7bbdce6ade982b
treedd1420a157c9ce01c4d7297a380b8e8dcb86cb09
parent8a9579ca29df951ace35125873949e905fd1af2b
make-directory now returns t if dir already exists

This new feature will help fix a copy-directory bug (Bug#58919).
Its implementation does not rely on make-directory handlers
supporting the new feature, as it no longer uses a make-directory
handler H in any way other than (funcall H DIR), thus using
only the intersection of the old and new behavior for handlers.
This will give us time to fix handlers at our leisure.
* lisp/files.el (files--ensure-directory): New arg MKDIR.
All uses changed.
(files--ensure-directory, make-directory):
Return non-nil if DIR is already a directory.  All uses changed.
* test/lisp/files-tests.el (files-tests-make-directory):
Test new return-value convention.
doc/lispref/files.texi
etc/NEWS
lisp/files.el
test/lisp/files-tests.el