diff options
| -rw-r--r-- | lisp/files.el | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/lisp/files.el b/lisp/files.el index 96cc510a61c..688b71b5bd4 100644 --- a/lisp/files.el +++ b/lisp/files.el | |||
| @@ -1585,8 +1585,17 @@ or multiple mail buffers, etc." | |||
| 1585 | (set-buffer-modified-p (buffer-modified-p)))) ; force mode line update | 1585 | (set-buffer-modified-p (buffer-modified-p)))) ; force mode line update |
| 1586 | 1586 | ||
| 1587 | (defun make-directory (dir &optional parents) | 1587 | (defun make-directory (dir &optional parents) |
| 1588 | "Create the directory DIR and any nonexistent parent dirs." | 1588 | "Create the directory DIR and any nonexistent parent dirs. |
| 1589 | (interactive "FMake directory: \nP") | 1589 | Interactively, the default choice of directory to create |
| 1590 | is the current default directory for file names. | ||
| 1591 | That is useful when you have visited a file in a nonexistint directory. | ||
| 1592 | |||
| 1593 | Noninteractively, the second (optional) argument PARENTS says whether | ||
| 1594 | to create parent directories if they don't exist." | ||
| 1595 | (interactive | ||
| 1596 | (list (read-file-name "Make directory: " default-directory default-directory | ||
| 1597 | nil nil) | ||
| 1598 | t)) | ||
| 1590 | (let ((handler (find-file-name-handler dir))) | 1599 | (let ((handler (find-file-name-handler dir))) |
| 1591 | (if handler | 1600 | (if handler |
| 1592 | (funcall handler 'make-directory dir parents) | 1601 | (funcall handler 'make-directory dir parents) |