[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/annotate 2050c59af3 227/372: - marked buffer as unmodified
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/annotate 2050c59af3 227/372: - marked buffer as unmodified when switching database and the only |
Date: |
Fri, 4 Feb 2022 16:59:02 -0500 (EST) |
branch: elpa/annotate
commit 2050c59af362295a2501d6ec73812e264350bc35
Author: cage <cage-invalid@invalid>
Commit: cage <cage-invalid@invalid>
- marked buffer as unmodified when switching database and the only
change occurred in a buffer was reloading the minor mode (annotate-mode);
- updating Changelog, News and version number.
---
Changelog | 7 ++++++-
NEWS.org | 3 +++
README.org | 12 ++++++++++--
annotate.el | 15 +++++++++------
4 files changed, 28 insertions(+), 9 deletions(-)
diff --git a/Changelog b/Changelog
index 5b572e1e82..bfcb15ccf1 100644
--- a/Changelog
+++ b/Changelog
@@ -1,10 +1,15 @@
+2020-06-09 Bastian Bechtold, cage
+ * annotate.el (annotate-buffers-annotate-mode, annotate-switch-db)
+ - added functions to switch the database of annotations used for the
emacs session;
+ - increased version to 0.7.1
+
2020-05-18 Bastian Bechtold, cage
* annotate.el
- Increased version to 0.7.0 for stable release
2020-01-25 Bastian Bechtold, cage
- * annotate.el (defun annotate-annotation-force-newline-policy,
+ * annotate.el (annotate-annotation-force-newline-policy,
annotate-annotation-newline-policy-forced-p,
annotate-create-annotation,
annotate-lineate,
diff --git a/NEWS.org b/NEWS.org
index 9c9f82552a..395afe503b 100644
--- a/NEWS.org
+++ b/NEWS.org
@@ -114,3 +114,6 @@
- 2020-05-18 V0.7.0 Bastian Bechtold, cage ::
Increased version to 0.7.0 for stable release
+
+- 2020-06-09 V0.7.1 Bastian Bechtold, cage ::
+ The database of annotation can be changed using the command
~annotate-switch-db~.
diff --git a/README.org b/README.org
index a978e841f7..19c655be97 100644
--- a/README.org
+++ b/README.org
@@ -30,8 +30,16 @@ previous annotation.
** Metadata
-All annotations are saved in ~annotate-file~ (=~/.annotations= by
-default).
+The current database for annotations is contained in the file
+indicated by the variable ~annotate-file~ (=~/.emacs.d/annotations= by
+default) but each user can change this value in a dynamic way using
+the command ~annotate-switch-db~. This command will take care to
+refresh/redraw all annotations in the buffers that uses
+~annotate-mode~.
+
+Please note that switching database, in this context, means rebinding
+the aforementioned variable (~annotate-file~). This means than no
+more than a single database can be active for each Emacs session.
Users of
[[https://github.com/emacscollective/no-littering][no-littering]]
diff --git a/annotate.el b/annotate.el
index b690608e6d..9b7da0890a 100644
--- a/annotate.el
+++ b/annotate.el
@@ -7,7 +7,7 @@
;; Maintainer: Bastian Bechtold
;; URL: https://github.com/bastibe/annotate.el
;; Created: 2015-06-10
-;; Version: 0.7.0
+;; Version: 0.7.1
;; This file is NOT part of GNU Emacs.
@@ -55,7 +55,7 @@
;;;###autoload
(defgroup annotate nil
"Annotate files without changing them."
- :version "0.7.0"
+ :version "0.7.1"
:group 'text)
;;;###autoload
@@ -2516,7 +2516,7 @@ code, always use load files from trusted sources!"
(let ((new-db (read-file-name "Database file location: ")))
(when (not (annotate-string-empty-p new-db))
(if (file-exists-p new-db)
- (let* ((confirm-message "Loading elisp file from untrusted source
may results in severe security problems. Load %S? [y/N]")
+ (let* ((confirm-message "Loading elisp file from untrusted source
may results in severe security problems. Load %S? [y/N] ")
(load-file-confirmed (if force-load
t
(string= (read-from-minibuffer (format
confirm-message
@@ -2527,9 +2527,12 @@ code, always use load files from trusted sources!"
(setf annotate-file new-db)
(cl-loop for annotated-buffer in
(annotate-buffers-annotate-mode) do
(with-current-buffer annotated-buffer
- (annotate-with-inhibit-modification-hooks
- (annotate-mode -1)
- (annotate-mode 1)))))
+ (let ((buffer-was-modified-p (buffer-modified-p
annotated-buffer)))
+ (annotate-with-inhibit-modification-hooks
+ (annotate-mode -1)
+ (annotate-mode 1)
+ (when (not buffer-was-modified-p)
+ (set-buffer-modified-p nil)))))))
(message "Load aborted by the user")))
(user-error (format "The file %S does not exists." new-db))))))
- [nongnu] elpa/annotate ca86e4a511 187/372: - removed org-mode from blacklist., (continued)
- [nongnu] elpa/annotate ca86e4a511 187/372: - removed org-mode from blacklist., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 822ed91a87 206/372: - fixed exporting and integrations of annotations;, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 5e2609e16e 207/372: - optimized 'annotate-previous-annotation-ends' and 'annotate-next-annotation-starts'., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 085791450c 215/372: - changed version number., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate c72e730ba3 217/372: - fixed annotation picking in 'annotate-annotate', ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate a38a2ff6b4 221/372: - updated version and documentation., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate bb8cda2edc 238/372: - actually changed version number., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate e2fed2fbcf 246/372: - removed useless spaces., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 85520c0202 228/372: - fixed version number., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 3f0c28cab6 241/372: - fixed a bug that allowed to create an annotation with an empty text., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 2050c59af3 227/372: - marked buffer as unmodified when switching database and the only,
ELPA Syncer <=
- [nongnu] elpa/annotate 99d99e5bcb 234/372: Merge pull request #72 from cage2/master, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 4b2fa8f61e 252/372: - removed function 'annotate-load-annotation-data-ignore-errors'., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate c972641056 258/372: - Using "help-echo" to print annotations instead of render it on the buffer., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 9320918b91 270/372: Merge pull request #84 from cage2/fix-regression-multiline-annotations, ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 3e70e187b3 262/372: - updated NEWS and Changelog., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 4af196ce04 312/372: - updated Changelog and NEWS.org., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 3a4dc507c2 305/372: - removed unused functions., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate 3458b548f4 303/372: - removed warning related to misplaced '(interactive)', ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate ed5f00d51c 351/372: - increased version number., ELPA Syncer, 2022/02/04
- [nongnu] elpa/annotate ffd6bbcc11 340/372: - allowed paths with spaces in a search query., ELPA Syncer, 2022/02/04