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

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

[elpa] externals/disk-usage 349719b 11/26: Display symlink targets


From: Pierre Neidhardt
Subject: [elpa] externals/disk-usage 349719b 11/26: Display symlink targets
Date: Tue, 26 Feb 2019 03:06:38 -0500 (EST)

branch: externals/disk-usage
commit 349719b4370e0361e3ae480d07e1012a68a43f6d
Author: Pierre Neidhardt <address@hidden>
Commit: Pierre Neidhardt <address@hidden>

    Display symlink targets
---
 disk-usage.el | 14 ++++++++------
 1 file changed, 8 insertions(+), 6 deletions(-)

diff --git a/disk-usage.el b/disk-usage.el
index d80fda6..b035aeb 100644
--- a/disk-usage.el
+++ b/disk-usage.el
@@ -53,8 +53,6 @@
 (require 'tabulated-list)
 (eval-when-compile (require 'cl-lib))
 
-;; TODO: Retest symlinks arrows.
-
 ;; TODO: Filter out files by date.  Make generic filter function?  Could factor
 ;; disk-usage-files into this.
 
@@ -314,15 +312,19 @@ FILE-ENTRY may be a string or a button."
                      file-entry))
          (formatted-filename
           (cond
+           ;; Symlinks
            ((stringp (file-attribute-type (file-attributes filename)))
-            (propertize (funcall disk-usage--format-files filename)
-                        'face (if (file-directory-p filename)
-                                  'disk-usage-symlink-directory
-                                'disk-usage-symlink)))
+            (concat (propertize (funcall disk-usage--format-files filename)
+                                'face (if (file-directory-p filename)
+                                          'disk-usage-symlink-directory
+                                        'disk-usage-symlink))
+                    " -> " (file-attribute-type (file-attributes filename))))
+           ;; Directories
            ((and (not (null (file-attribute-type (file-attributes filename))))
                  (not (file-accessible-directory-p filename)))
             (propertize (funcall disk-usage--format-files filename)
                         'face 'disk-usage-inaccessible))
+           ;; Regular files
            (t (funcall disk-usage--format-files filename)))))
     (if (listp file-entry)
         (let ((copy (cl-copy-list file-entry)))



reply via email to

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