New MELPA Package: ddate
• Erik L. Arneson
I recently wrote an Emacs Lisp package to support the ddate command, a classic command-line utility to display dates from the Discordian calendar.
The package is now available on MELPA! That means that if you have use-package
installed, you can get ddate
easily like this:
(use-package ddate :ensure t)
Once you have the ddate
package installed, you can use it to add the Discordian date to your dashboard with code like
this:
(defun ela/dashboard-insert-ddate (list-size)
"Insert the Discordian date into the dashboard."
(let ((ddate-string (ddate-pretty)))
(dashboard-center-line ddate-string)
(insert ddate-string)))
(use-package dashboard
:init (dashboard-setup-startup-hook)
:config
;; Add the ddate item provider to the list.
(add-to-list 'dashboard-item-generators
'(ddate . ela/dashboard-insert-ddate))
;; Set up your items with ddate at the top.
(setq dashboard-items '((ddate)
(recents . 5)
(bookmarks . 5)
(registers . 5))))
You can view the source code for ddate
on Sourcehut.