diff options
| author | Dan Nicolaescu | 2008-06-24 04:04:48 +0000 |
|---|---|---|
| committer | Dan Nicolaescu | 2008-06-24 04:04:48 +0000 |
| commit | 2a520399dcd0a3eecfca660abb06456534e9103c (patch) | |
| tree | 9e8648de4bbcbbaf6b8206556635598c6622315e /lisp | |
| parent | c4c0a44b61d3b85bd0b7fc0d7fdab33931f4aa7a (diff) | |
| download | emacs-2a520399dcd0a3eecfca660abb06456534e9103c.tar.gz emacs-2a520399dcd0a3eecfca660abb06456534e9103c.zip | |
* add-log.el (add-change-log-entry): Add new arg to force each new
entry to be on a new line.
* diff-mode.el (diff-add-change-log-entries-other-window): Use it.
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/ChangeLog | 14 | ||||
| -rw-r--r-- | lisp/add-log.el | 14 | ||||
| -rw-r--r-- | lisp/diff-mode.el | 2 |
3 files changed, 20 insertions, 10 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 49a997095df..4d40fb44666 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,5 +1,9 @@ | |||
| 1 | 2008-06-24 Dan Nicolaescu <dann@ics.uci.edu> | 1 | 2008-06-24 Dan Nicolaescu <dann@ics.uci.edu> |
| 2 | 2 | ||
| 3 | * add-log.el (add-change-log-entry): Add new arg to force each new | ||
| 4 | entry to be on a new line. | ||
| 5 | * diff-mode.el (diff-add-change-log-entries-other-window): Use it. | ||
| 6 | |||
| 3 | * vc-dir.el (vc-client-object): Remove. | 7 | * vc-dir.el (vc-client-object): Remove. |
| 4 | (vc-dir-prepare-status-buffer): Take a backend as an argument and | 8 | (vc-dir-prepare-status-buffer): Take a backend as an argument and |
| 5 | use it when looking for a buffer. | 9 | use it when looking for a buffer. |
| @@ -17,11 +21,11 @@ | |||
| 17 | 21 | ||
| 18 | * vc.el (Todo): Update. | 22 | * vc.el (Todo): Update. |
| 19 | 23 | ||
| 20 | * vc-hg.el (vc-annotate-convert-time, vc-default-status-printer): | 24 | * vc-hg.el (vc-annotate-convert-time, vc-default-status-printer): |
| 21 | * vc-rcs.el (vc-annotate-convert-time): | 25 | * vc-rcs.el (vc-annotate-convert-time): |
| 22 | * vc-mtn.el (vc-annotate-convert-time): | 26 | * vc-mtn.el (vc-annotate-convert-time): |
| 23 | * vc-git.el (vc-annotate-convert-time): | 27 | * vc-git.el (vc-annotate-convert-time): |
| 24 | * vc-cvs.el (vc-annotate-convert-time): | 28 | * vc-cvs.el (vc-annotate-convert-time): |
| 25 | * vc-bzr.el (vc-annotate-convert-time): Declare as functions. | 29 | * vc-bzr.el (vc-annotate-convert-time): Declare as functions. |
| 26 | 30 | ||
| 27 | 2008-06-23 Dan Nicolaescu <dann@ics.uci.edu> | 31 | 2008-06-23 Dan Nicolaescu <dann@ics.uci.edu> |
diff --git a/lisp/add-log.el b/lisp/add-log.el index 1130347b918..fc8224293ca 100644 --- a/lisp/add-log.el +++ b/lisp/add-log.el | |||
| @@ -518,7 +518,8 @@ Optional arg BUFFER-FILE overrides `buffer-file-name'." | |||
| 518 | buffer-file)))) | 518 | buffer-file)))) |
| 519 | 519 | ||
| 520 | ;;;###autoload | 520 | ;;;###autoload |
| 521 | (defun add-change-log-entry (&optional whoami file-name other-window new-entry) | 521 | (defun add-change-log-entry (&optional whoami file-name other-window new-entry |
| 522 | put-new-entry-on-new-line) | ||
| 522 | "Find change log file, and add an entry for today and an item for this file. | 523 | "Find change log file, and add an entry for today and an item for this file. |
| 523 | Optional arg WHOAMI (interactive prefix) non-nil means prompt for user | 524 | Optional arg WHOAMI (interactive prefix) non-nil means prompt for user |
| 524 | name and email (stored in `add-log-full-name' and `add-log-mailing-address'). | 525 | name and email (stored in `add-log-full-name' and `add-log-mailing-address'). |
| @@ -532,6 +533,10 @@ Fourth arg NEW-ENTRY non-nil means always create a new entry at the front; | |||
| 532 | never append to an existing entry. Option `add-log-keep-changes-together' | 533 | never append to an existing entry. Option `add-log-keep-changes-together' |
| 533 | otherwise affects whether a new entry is created. | 534 | otherwise affects whether a new entry is created. |
| 534 | 535 | ||
| 536 | Fifth arg PUT-NEW-ENTRY-ON-NEW-LINE non-nil means that if a new | ||
| 537 | entry is created, put it on a new line by itself, do not put it | ||
| 538 | after a comma on an existing line. | ||
| 539 | |||
| 535 | Option `add-log-always-start-new-record' non-nil means always create a | 540 | Option `add-log-always-start-new-record' non-nil means always create a |
| 536 | new record, even when the last record was made on the same date and by | 541 | new record, even when the last record was made on the same date and by |
| 537 | the same person. | 542 | the same person. |
| @@ -679,7 +684,8 @@ non-nil, otherwise in local time." | |||
| 679 | (let ((pos (point-marker))) | 684 | (let ((pos (point-marker))) |
| 680 | (skip-syntax-backward " ") | 685 | (skip-syntax-backward " ") |
| 681 | (skip-chars-backward "):") | 686 | (skip-chars-backward "):") |
| 682 | (if (and (looking-at "):") | 687 | (if (and (not put-new-entry-on-new-line) |
| 688 | (looking-at "):") | ||
| 683 | (let ((pos (save-excursion (backward-sexp 1) (point)))) | 689 | (let ((pos (save-excursion (backward-sexp 1) (point)))) |
| 684 | (when (equal (buffer-substring pos (point)) defun) | 690 | (when (equal (buffer-substring pos (point)) defun) |
| 685 | (delete-region pos (point))) | 691 | (delete-region pos (point))) |
| @@ -687,8 +693,8 @@ non-nil, otherwise in local time." | |||
| 687 | (progn (skip-chars-backward ", ") | 693 | (progn (skip-chars-backward ", ") |
| 688 | (delete-region (point) pos) | 694 | (delete-region (point) pos) |
| 689 | (unless (memq (char-before) '(?\()) (insert ", "))) | 695 | (unless (memq (char-before) '(?\()) (insert ", "))) |
| 690 | (if (looking-at "):") | 696 | (when (and (not put-new-entry-on-new-line) (looking-at "):")) |
| 691 | (delete-region (+ 1 (point)) (line-end-position))) | 697 | (delete-region (+ 1 (point)) (line-end-position))) |
| 692 | (goto-char pos) | 698 | (goto-char pos) |
| 693 | (insert "(")) | 699 | (insert "(")) |
| 694 | (set-marker pos nil)) | 700 | (set-marker pos nil)) |
diff --git a/lisp/diff-mode.el b/lisp/diff-mode.el index 447a8446250..864d74b4e30 100644 --- a/lisp/diff-mode.el +++ b/lisp/diff-mode.el | |||
| @@ -1875,7 +1875,7 @@ I.e. like `add-change-log-entry-other-window' but applied to all hunks." | |||
| 1875 | "\\( .*\n\\)*[+]\\)?") | 1875 | "\\( .*\n\\)*[+]\\)?") |
| 1876 | nil t)) | 1876 | nil t)) |
| 1877 | (save-excursion | 1877 | (save-excursion |
| 1878 | (add-change-log-entry nil nil t t))) | 1878 | (add-change-log-entry nil nil t nil t))) |
| 1879 | ;; When there's no more hunks, diff-hunk-next signals an error. | 1879 | ;; When there's no more hunks, diff-hunk-next signals an error. |
| 1880 | (error nil))))) | 1880 | (error nil))))) |
| 1881 | 1881 | ||