Thierry Volpiatto writes: > Hi, > in dired when using `dired-listing-switches' with -h option, the second > line of dired buffer is like: > > total used in directory 24M available 19275100 > > it should show: > > total used in directory 24M available 19G > > I suggest to modify `insert-directory' like this: > > ,----[ files.el (insert-directory) ] > | [....] > | (let* ((directory-free-space-args (if (string-match "h" dired-listing-switches) > | (concat directory-free-space-args "h") > | directory-free-space-args)) > | (available (get-free-disk-space "."))) > | (when (re-search-forward "^ *\\(total\\)" nil t) > | (when available > | ;; Replace "total" with "used", to avoid confusion. > | (replace-match "total used in directory" nil nil nil 1) > | (end-of-line) > | (insert " available " available)))))))))) > `---- > > Find a patch attached. Even better is to parse `dired-actual-switches', like that it update correctly when using C-u s in dired. Find the precedent patch modified here. -- Thierry Volpiatto Gpg key: http://pgp.mit.edu/