Plaster

common-lisp
(let* ((result (make-list 0 nil)) (sources `(,@(agenda-life-clocktable-files) ,@(agenda-work-clocktable-files) ,(concat org-directory "/git/pmaint/obl.org") ,(concat org-directory "/git/pmaint/sleep.org") ,(concat org-directory "/git/pmaint/other-pmaint.org") ,(concat org-directory "/git/pmaint/meals.org")))) (save-excursion (setq result (loop for i in sources append (with-current-buffer (or (find-buffer-visiting i) (find-file i) (find-buffer-visiting i)) (loop for j in (org-element-map (org-element-parse-buffer) 'clock (lambda (x) (let ((timestamp (org-element-property :value x))) (list (file-name-nondirectory i) (progn (goto-char (org-element-property :begin x)) (org-entry-get nil "CATEGORY")) (format "%d-%02d-%02dT%02d:%02d" (org-element-property :year-start timestamp) (org-element-property :month-start timestamp) (org-element-property :day-start timestamp) (org-element-property :hour-start timestamp) (org-element-property :minute-start timestamp)) (format "%d-%02d-%02dT%02d:%02d" (org-element-property :year-end timestamp) (org-element-property :month-end timestamp) (org-element-property :day-end timestamp) (org-element-property :hour-end timestamp) (org-element-property :minute-end timestamp)))))) collect j)))) (subseq result 0 20)))