Make the xdg dependency optional
We now default to using `~/.cache/waybar-current-task.json` if the `xdg` package is not present.
This commit is contained in:
parent
754fd9d2fa
commit
c327eb18c6
@ -38,7 +38,7 @@
|
||||
|
||||
;;; Code:
|
||||
|
||||
(require 'xdg)
|
||||
(require 'xdg nil t)
|
||||
(require 'json)
|
||||
(require 'org-clock)
|
||||
|
||||
@ -47,7 +47,9 @@
|
||||
:group 'emacs)
|
||||
|
||||
(defcustom org-clock-waybar-filename
|
||||
(if (fboundp 'xdg-cache-home)
|
||||
(expand-file-name "waybar-current-task.json" (xdg-cache-home))
|
||||
(expand-file-name "~/.cache/waybar-current-task.json"))
|
||||
"Name of the file to save task data to."
|
||||
:type 'string
|
||||
:group 'org-clock-waybar)
|
||||
|
Loading…
Reference in New Issue
Block a user