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

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

[elpa] externals/denote 5195f13f55 197/355: Add optional absolute for de


From: ELPA Syncer
Subject: [elpa] externals/denote 5195f13f55 197/355: Add optional absolute for denote--directory-files
Date: Sun, 26 Jun 2022 23:58:23 -0400 (EDT)

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

    Add optional absolute for denote--directory-files
    
    There is currently no use for it, but I am aware at least of one
    function we might use in the future which requires absolute paths.
---
 denote.el | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/denote.el b/denote.el
index 65120ac5e2..ec81e94c93 100644
--- a/denote.el
+++ b/denote.el
@@ -303,14 +303,16 @@ With optional N, search in the Nth line from point."
 
 ;;;; Keywords
 
-(defun denote--directory-files ()
-  "List note files, assuming flat directory."
+(defun denote--directory-files (&optional absolute)
+  "List note files, assuming flat directory.
+If optional ABSOLUTE, show full paths, else only show base file
+names that are relative to the variable `denote-directory'."
   (let* ((dir (denote-directory))
          (default-directory dir))
     (seq-remove
      (lambda (file)
        (file-directory-p file))
-     (directory-files dir nil directory-files-no-dot-files-regexp t))))
+     (directory-files dir absolute directory-files-no-dot-files-regexp t))))
 
 (defun denote--directory-files-matching-regexp (regexp)
   "Return list of files matching REGEXP."



reply via email to

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