[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/disk-usage 9fbcef0 3/5: Support spaces in du args.
From: |
Stefan Monnier |
Subject: |
[elpa] externals/disk-usage 9fbcef0 3/5: Support spaces in du args. |
Date: |
Wed, 17 Mar 2021 18:41:15 -0400 (EDT) |
branch: externals/disk-usage
commit 9fbcef08b81be448bf60c085b1bcd3b501112b3e
Author: Pierre Neidhardt <mail@ambrevar.xyz>
Commit: Pierre Neidhardt <mail@ambrevar.xyz>
Support spaces in du args.
---
disk-usage.el | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/disk-usage.el b/disk-usage.el
index c9d7865..18a0ac0 100644
--- a/disk-usage.el
+++ b/disk-usage.el
@@ -86,7 +86,7 @@
:type 'string)
(defvaralias 'disk-usage--du-args 'disk-usage-du-args)
-(defcustom disk-usage-du-args "-sb"
+(defcustom disk-usage-du-args "-s -b"
"Non-GNU users need GNU's `du' for the `-b' flag. See
`disk-usage-du-command'."
:type 'string)
@@ -386,9 +386,10 @@ Hard-links are taken into account."
(split-string
(with-temp-buffer
(with-output-to-string
- (process-file disk-usage-du-command
- nil '(t nil) nil
- disk-usage-du-args (file-local-name
path)))
+ (message "%S" (append (split-string
disk-usage-du-args) (list (file-local-name path))))
+ (apply #'process-file disk-usage-du-command
+ nil '(t nil) nil
+ (append (split-string disk-usage-du-args)
(list (file-local-name path)))))
(buffer-string))))))
0))
(defalias 'disk-usage--directory-size-with-du
'disk-usage-directory-size-with-du)