[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/denote 2d12ec7457 05/11: Refactor denote--id-exists-p
From: |
ELPA Syncer |
Subject: |
[elpa] externals/denote 2d12ec7457 05/11: Refactor denote--id-exists-p |
Date: |
Mon, 8 Aug 2022 23:57:31 -0400 (EDT) |
branch: externals/denote
commit 2d12ec7457d03c4fe8ba67e2d37f73fbf350e606
Author: Jean-Philippe Gagné Guay <jeanphilippe150@gmail.com>
Commit: Jean-Philippe Gagné Guay <jeanphilippe150@gmail.com>
Refactor denote--id-exists-p
---
denote.el | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/denote.el b/denote.el
index 6e8b7552f0..df37644b2c 100644
--- a/denote.el
+++ b/denote.el
@@ -895,11 +895,10 @@ where the former does not read dates without a time
component."
;; notes within fractions of a second).
(defun denote--id-exists-p (identifier)
"Return non-nil if IDENTIFIER already exists."
- (or (seq-some (lambda (file)
- (string-match-p (concat "\\`" identifier) file))
- (denote--buffer-file-names))
- (denote--directory-files-matching-regexp
- (concat "\\`" identifier))))
+ (seq-some (lambda (file)
+ (string-prefix-p identifier (file-name-nondirectory file)))
+ (concat (denote--directory-files :absolute)
+ (denote--buffer-file-names))))
(defun denote--barf-duplicate-id (identifier)
"Throw a user-error if IDENTIFIER already exists."
- [elpa] externals/denote updated (22bb68b86c -> 065a10fc60), ELPA Syncer, 2022/08/08
- [elpa] externals/denote 5d7f4f3cfc 01/11: Remove let-bindings of default-directory, ELPA Syncer, 2022/08/08
- [elpa] externals/denote 9b4310779f 09/11: Use absolute paths in denote--retrieve-files-in-xrefs and denote--retrieve-proces-grep, ELPA Syncer, 2022/08/08
- [elpa] externals/denote 2c00c3ed44 10/11: Fix backlinks buffer, ELPA Syncer, 2022/08/08
- [elpa] externals/denote 6793a4319d 02/11: Delete variable denote-link--links-to-files, ELPA Syncer, 2022/08/08
- [elpa] externals/denote 2d12ec7457 05/11: Refactor denote--id-exists-p,
ELPA Syncer <=
- [elpa] externals/denote d0a174082a 06/11: Remove the absolute parameter from denote--directory-files and delete denote--directory-files-recursively, ELPA Syncer, 2022/08/08
- [elpa] externals/denote 1e8b1b62b4 07/11: Refactor denote--buffer-file-names, ELPA Syncer, 2022/08/08
- [elpa] externals/denote 065a10fc60 11/11: Merge pull request #80 from jeanphilippegg/cleanup, ELPA Syncer, 2022/08/08
- [elpa] externals/denote 8a25727777 03/11: Remove check of current buffer in denote--id-exists-p, ELPA Syncer, 2022/08/08
- [elpa] externals/denote c925928795 04/11: Refactor denote--directory-files-matching-regexp, ELPA Syncer, 2022/08/08
- [elpa] externals/denote 769f497f17 08/11: Ignore hidden directories in denote--subdirs, ELPA Syncer, 2022/08/08