.emacs.d/init.d/basics/misc.el

22 lines
496 B
EmacsLisp
Raw Normal View History

2020-01-01 03:42:25 +01:00
;;; misc.el --- Basic things that do not fit any other category. -*- lexical-binding: t; -*-
;; Time-stamp: <2020-01-03T03:50:12+0100>
2020-01-01 03:42:25 +01:00
;;; Commentary:
;;; Code:
(use-package emacs
:ensure nil
:config
(defun my/message-with-timestamp (args)
"Prepend current timestamp to a `message' output."
(push (concat (format-time-string "[%FT%T] ") (car args)) (cdr args)))
2020-01-01 03:42:25 +01:00
(advice-add 'message :filter-args 'my/message-with-timestamp)
2020-01-01 03:42:25 +01:00
)
(provide 'basics/misc)
;;; misc.el ends here