diff options
| author | Eric S. Raymond | 2014-01-08 20:32:45 -0500 |
|---|---|---|
| committer | Eric S. Raymond | 2014-01-08 20:32:45 -0500 |
| commit | ceb885a181e38f2822892db045cce6abe8c3a285 (patch) | |
| tree | 1abcf0952465ddb22e174a442381271b58d727d9 | |
| parent | 314668368cbc57a7096e7e89df8b697c00cba03b (diff) | |
| download | emacs-ceb885a181e38f2822892db045cce6abe8c3a285.tar.gz emacs-ceb885a181e38f2822892db045cce6abe8c3a285.zip | |
Create a needed obsolete-variable alias. Fix up some docstrings.
| -rw-r--r-- | lisp/ChangeLog | 2 | ||||
| -rw-r--r-- | lisp/version.el | 32 |
2 files changed, 19 insertions, 15 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 711ceedab8a..a1eef95d776 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -4,7 +4,7 @@ | |||
| 4 | Bazaar-specific names. | 4 | Bazaar-specific names. |
| 5 | 5 | ||
| 6 | * version.el (emacs-bzr-version): Name changed to | 6 | * version.el (emacs-bzr-version): Name changed to |
| 7 | emacs-repository-version. | 7 | emacs-repository-version. Obsolete-variable alias made. |
| 8 | * loadup.el: Follow through on this name change. | 8 | * loadup.el: Follow through on this name change. |
| 9 | * lisp/mail/emacsbug.el (report-emacs-bug): Factor out any | 9 | * lisp/mail/emacsbug.el (report-emacs-bug): Factor out any |
| 10 | assumption about the version control system in use. | 10 | assumption about the version control system in use. |
diff --git a/lisp/version.el b/lisp/version.el index bdbdcb96c89..0362b03484c 100644 --- a/lisp/version.el +++ b/lisp/version.el | |||
| @@ -86,10 +86,12 @@ to the system configuration; look at `system-configuration' instead." | |||
| 86 | 86 | ||
| 87 | ;; Set during dumping, this is a defvar so that it can be setq'd. | 87 | ;; Set during dumping, this is a defvar so that it can be setq'd. |
| 88 | (defvar emacs-repository-version nil | 88 | (defvar emacs-repository-version nil |
| 89 | "String giving the bzr revision from which this Emacs was built. | 89 | "String giving the repository revision from which this Emacs was built. |
| 90 | The format is: [revno] revision_id, where revno may be absent. | 90 | Value is nil if Emacs was not built from a repository checkout, |
| 91 | Value is nil if Emacs was not built from a bzr checkout, or if we could | 91 | or if we could not determine the revision.") |
| 92 | not determine the revision.") | 92 | |
| 93 | (define-obsolete-variable-alias 'emacs-bzr-version | ||
| 94 | 'emacs-repository-version "24.4") | ||
| 93 | 95 | ||
| 94 | (defun emacs-bzr-version-dirstate (dir) | 96 | (defun emacs-bzr-version-dirstate (dir) |
| 95 | "Try to return as a string the bzr revision ID of directory DIR. | 97 | "Try to return as a string the bzr revision ID of directory DIR. |
| @@ -127,16 +129,18 @@ Returns nil if unable to find this information." | |||
| 127 | (buffer-string)))) | 129 | (buffer-string)))) |
| 128 | 130 | ||
| 129 | (defun emacs-repository-get-version (&optional dir external) | 131 | (defun emacs-repository-get-version (&optional dir external) |
| 130 | "Try to return as a string the bzr revision of the Emacs sources. | 132 | "Try to return as a string the repository revision of the Emacs sources. |
| 131 | The format is: [revno] revision_id, where revno may be absent. | 133 | The format of the returned string is dependent on the VCS in use. |
| 132 | Value is nil if the sources do not seem to be under bzr, or if we could | 134 | Value is nil if the sources do not seem to be under version |
| 133 | not determine the revision. Note that this reports on the current state | 135 | control, or if we could not determine the revision. Note that |
| 134 | of the sources, which may not correspond to the running Emacs. | 136 | this reports on the current state of the sources, which may not |
| 135 | 137 | correspond to the running Emacs. | |
| 136 | Optional argument DIR is a directory to use instead of `source-directory'. | 138 | |
| 137 | Optional argument EXTERNAL non-nil means to maybe ask `bzr' itself, | 139 | Optional argument DIR is a directory to use instead of |
| 138 | if the sources appear to be under bzr. If `force', always ask bzr. | 140 | `source-directory'. Optional argument EXTERNAL non-nil means to |
| 139 | Otherwise only ask bzr if we cannot find any information ourselves." | 141 | maybe ask the VCS itself, if the sources appear to be under |
| 142 | version control. If `force', always ask. the VCS. Otherwise | ||
| 143 | only ask the VCS if we cannot find any information ourselves." | ||
| 140 | (or dir (setq dir source-directory)) | 144 | (or dir (setq dir source-directory)) |
| 141 | (when (file-directory-p (expand-file-name ".bzr/branch" dir)) | 145 | (when (file-directory-p (expand-file-name ".bzr/branch" dir)) |
| 142 | (if (eq external 'force) | 146 | (if (eq external 'force) |