emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/denote ecaaa6bb63 259/355: Only consider items with id


From: ELPA Syncer
Subject: [elpa] externals/denote ecaaa6bb63 259/355: Only consider items with id in directory files
Date: Sun, 26 Jun 2022 23:58:30 -0400 (EDT)

branch: externals/denote
commit ecaaa6bb63d43b1d0583253e0b2d530bbcebda37
Author: Protesilaos Stavrou <info@protesilaos.com>
Commit: Protesilaos Stavrou <info@protesilaos.com>

    Only consider items with id in directory files
    
    This way we avoid other random files that may exist in the directory,
    such as .dir-locals.el
---
 denote.el | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/denote.el b/denote.el
index f1e7b414f7..08944f17d8 100644
--- a/denote.el
+++ b/denote.el
@@ -293,7 +293,8 @@ names that are relative to the variable `denote-directory'."
          (default-directory dir))
     (seq-remove
      (lambda (file)
-       (file-directory-p file))
+       (or (not (string-match-p denote--id-regexp file))
+           (file-directory-p file)))
      (directory-files dir absolute directory-files-no-dot-files-regexp t))))
 
 (defun denote--directory-files-matching-regexp (regexp &optional 
no-check-current)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]