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

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

[elpa] master a37d4e3 072/399: counsel.el (counsel-compile): fix breakag


From: Oleh Krehel
Subject: [elpa] master a37d4e3 072/399: counsel.el (counsel-compile): fix breakage to subdir recursion
Date: Sat, 20 Jul 2019 14:56:51 -0400 (EDT)

branch: master
commit a37d4e34ef566df5cfc42c725c3c97252f41ab40
Author: Alex Bennée <address@hidden>
Commit: Oleh Krehel <address@hidden>

    counsel.el (counsel-compile): fix breakage to subdir recursion
    
    Commit 1439e8d broke subdir recursion by only passing the directory
    containing the subdirs rather than the final subdir. Fix this by
    partially reverting the change while keeping the new cleaner
    structure.
---
 counsel.el | 15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)

diff --git a/counsel.el b/counsel.el
index 7e989ed..2d54e07 100644
--- a/counsel.el
+++ b/counsel.el
@@ -5233,13 +5233,14 @@ subdirectories that builds may be invoked in."
   "Return a list of potential build directories."
   (let* ((srcdir (or dir (counsel--compile-root)))
          (blddir (counsel--find-build-subdir srcdir))
-         (props `(srcdir ,srcdir blddir ,blddir recursive t)))
-    (mapcar (lambda (s)
-              (setq s (concat (propertize "Select build in "
-                                          'face 'font-lock-warning-face)
-                              (propertize s 'face 'dired-directory)))
-              (add-text-properties 0 (length s) props s)
-              s)
+         (props `(srcdir ,srcdir recursive t))
+         (fmt (concat (propertize "Select build in "
+                                  'face 'font-lock-warning-face)
+                      (propertize "%s" 'face 'dired-directory))))
+    (mapcar (lambda (subdir)
+              (let ((s (format fmt subdir)))
+                (add-text-properties 0 (length s) `(blddir ,subdir ,@props) s)
+                s))
             (and blddir (counsel--get-build-subdirs blddir)))))
 
 ;; No easy way to make directory local, would buffer local make more sense?



reply via email to

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