diff options
| -rw-r--r-- | lisp/add-log.el | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/lisp/add-log.el b/lisp/add-log.el index 9cc2e2d36f8..734fa5ebf86 100644 --- a/lisp/add-log.el +++ b/lisp/add-log.el | |||
| @@ -77,16 +77,22 @@ This defaults to the value of `user-mail-address'.") | |||
| 77 | "Find a change log file for \\[add-change-log-entry] and return the name. | 77 | "Find a change log file for \\[add-change-log-entry] and return the name. |
| 78 | 78 | ||
| 79 | Optional arg FILE-NAME specifies the file to use. | 79 | Optional arg FILE-NAME specifies the file to use. |
| 80 | If FILE-NAME is nil, use the value of `change-log-default-name' if non-nil. | 80 | If FILE-NAME is nil, use the value of `change-log-default-name'. |
| 81 | Otherwise, search in the current directory and its successive parents | 81 | If 'change-log-default-name' is nil, behave as though it were 'ChangeLog' |
| 82 | for a file named `ChangeLog' (or whatever we use on this operating system). | 82 | \(or whatever we use on this operating system). |
| 83 | |||
| 84 | If 'change-log-default-name' contains a leading directory component, then | ||
| 85 | simply find it in the current directory. Otherwise, search in the current | ||
| 86 | directory and its successive parents for a file so named. | ||
| 83 | 87 | ||
| 84 | Once a file is found, `change-log-default-name' is set locally in the | 88 | Once a file is found, `change-log-default-name' is set locally in the |
| 85 | current buffer to the complete file name." | 89 | current buffer to the complete file name." |
| 86 | ;; If user specified a file name or if this buffer knows which one to use, | 90 | ;; If user specified a file name or if this buffer knows which one to use, |
| 87 | ;; just use that. | 91 | ;; just use that. |
| 88 | (or file-name | 92 | (or file-name |
| 89 | (setq file-name change-log-default-name) | 93 | (setq file-name (and change-log-default-name |
| 94 | (file-name-directory change-log-default-name) | ||
| 95 | change-log-default-name)) | ||
| 90 | (progn | 96 | (progn |
| 91 | ;; Chase links in the source file | 97 | ;; Chase links in the source file |
| 92 | ;; and use the change log in the dir where it points. | 98 | ;; and use the change log in the dir where it points. |