Skip to content

Instantly share code, notes, and snippets.

@aggieben
Created June 10, 2009 13:56
Show Gist options
  • Save aggieben/127223 to your computer and use it in GitHub Desktop.
Save aggieben/127223 to your computer and use it in GitHub Desktop.
(in-package :slimtimer)
(export '(time-entry-task task-name task-hours task-last))
(require :s-xml)
(defmacro with-xml (&body body)
`(with-output-to-string (ss)
(format ss "<?xml version=1.0\" encoding=\"utf-8\"?>")
(cl-who:with-html-output (ss)
,@body)))
(defun mkstr (&rest args)
(with-output-to-string (ss)
(dolist (a args) (princ a ss))))
(defmacro time-entry-task (entry)
`(fifth ,entry))
(defmacro task-name (task)
`(cadr (second (cdr ,task))))
(defmacro task-id (task)
`(cadr (nth 6 (cdr ,task))))
(defmacro task-hours (task)
`(cadr (nth 8 (cdr ,task))))
(defmacro task-last (task)
`(cadr (nth 2 (cdr ,task))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment