From: Lars Ingebrigtsen Date: Tue, 30 Jul 2019 11:10:03 +0000 (+0200) Subject: Use decoded time accessors in in em-ls X-Git-Tag: emacs-27.0.90~1817^2~16 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=bddd4d382a0e91c73326f1e278924ce9e5624cd7;p=emacs.git Use decoded time accessors in in em-ls * lisp/eshell/em-ls.el (eshell-ls-file): Use decoded time accessors. --- diff --git a/lisp/eshell/em-ls.el b/lisp/eshell/em-ls.el index 89969d32582..b1aab79538f 100644 --- a/lisp/eshell/em-ls.el +++ b/lisp/eshell/em-ls.el @@ -525,12 +525,14 @@ whose cdr is the list of file attributes." " " (format-time-string (concat eshell-ls-date-format " " - (if (= (nth 5 (decode-time)) - (nth 5 (decode-time - (nth (cond - ((eq sort-method 'by-atime) 4) - ((eq sort-method 'by-ctime) 6) - (t 5)) attrs)))) + (if (= (decoded-time-year (decode-time)) + (decoded-time-year + (decode-time + (nth (cond + ((eq sort-method 'by-atime) 4) + ((eq sort-method 'by-ctime) 6) + (t 5)) + attrs)))) "%H:%M" " %Y")) (nth (cond ((eq sort-method 'by-atime) 4)