Skip to content

Instantly share code, notes, and snippets.

@spiderbit
Created June 17, 2014 02:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save spiderbit/c73ace207c33e519eedf to your computer and use it in GitHub Desktop.
Save spiderbit/c73ace207c33e519eedf to your computer and use it in GitHub Desktop.
(defun daylight-get-theme (hour)
"Return the daylight theme for HOUR."
(cond ((and (>= hour daylight-morning-hour) (< hour daylight-afternoon-hour))
daylight-morning-theme)
((and (>= hour daylight-afternoon-hour) (< hour daylight-evening-hour))
daylight-afternoon-theme)
((and (or (>= hour daylight-evening-hour) ( < hour daylight-morning-hour))
(or (<= hour daylight-late-hour) (> hour daylight-morning-hour)))
daylight-evening-theme)
(t
daylight-late-theme)))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment