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

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

[elpa] master 45a41db: Speed up the load of the dired buffer


From: Tino Calancha
Subject: [elpa] master 45a41db: Speed up the load of the dired buffer
Date: Mon, 24 Sep 2018 06:44:06 -0400 (EDT)

branch: master
commit 45a41dbd207fa31c7915b2a93098110d32e99802
Author: Tino Calancha <address@hidden>
Commit: Tino Calancha <address@hidden>

    Speed up the load of the dired buffer
    
    It has been noted that we can significantly speed up the load
    of the Dired buffer by checking more often the completion of the
    `du' processes.
    Problem reported by Pierre Neidhardt here:
    https://github.com/calancha/dired-du/issues/1
    * packages/dired-du/dired-du.el 
(dired-du-get-recursive-dir-size-in-parallel): check
    for `du' process completion more often.
---
 packages/dired-du/dired-du.el | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/packages/dired-du/dired-du.el b/packages/dired-du/dired-du.el
index 7020170..429bb81 100644
--- a/packages/dired-du/dired-du.el
+++ b/packages/dired-du/dired-du.el
@@ -9,9 +9,9 @@
 ;; Created: Wed Mar 23 22:54:00 2016
 ;; Version: 0.5
 ;; Package-Requires: ((emacs "24.4") (cl-lib "0.5"))
-;; Last-Updated: Sat May 27 18:30:02 JST 2017
+;; Last-Updated: Mon Sep 24 19:40:04 JST 2018
 ;;           By: calancha
-;;     Update #: 339
+;;     Update #: 340
 ;; Compatibility: GNU Emacs: 24.4
 
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
@@ -665,7 +665,10 @@ The return value is an alist (DIRNAME . SIZE)."
                                (setq old completed))
                              (setq completed (count-lines (point-min)
                                                           (point-max)))
-                             (sleep-for 1))))
+                             ;; Give a bit of time to the process to end.  
Initially we
+                             ;; were waiting 1 s; it turned out to be too 
conservative value.
+                             ;; TODO: Shouldn't this be run in a sentinel?
+                             (sleep-for 0 10))))
                        ;; collect dir sizes.
                        (goto-char 1)
                        (while (re-search-forward "^[0-9]+" nil t)



reply via email to

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