Skip to content

Instantly share code, notes, and snippets.

@nhunzaker
Last active April 26, 2021 07:34
Show Gist options
  • Save nhunzaker/6fa5f50f041c99d7c0ba8bf13939e4e9 to your computer and use it in GitHub Desktop.
Save nhunzaker/6fa5f50f041c99d7c0ba8bf13939e4e9 to your computer and use it in GitHub Desktop.
(defun nh/today-as-string ()
"Today, as a string."
(format-time-string "%y.%m.%d"))
(defun current-workbook ()
"Location of the current workbook log file."
(concat "~/.org/worklog/" (nh/today-as-string) ".org"))
(defun workbook ()
"Opens up my workbook."
(interactive)
(find-file (current-workbook))
(when (not (file-exists-p (current-workbook)))
(insert-before-markers
(concat "#+TITLE: " (format-time-string "%B %d, %Y")) "\n" "#+STARTUP: content\n")))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment