From d384b7b4158ba7f517c83a21203abaef75f330b2 Mon Sep 17 00:00:00 2001 From: Mike 'Fuzzy' Partin Date: Wed, 10 Jul 2024 02:33:56 -0700 Subject: [PATCH] ensure ~/.org-agenda is created if missing --- thwap/thwap-helpers.el | 1 + thwap/thwap-orgmode.el | 1 + 2 files changed, 2 insertions(+) diff --git a/thwap/thwap-helpers.el b/thwap/thwap-helpers.el index bada8bb..bc935c5 100644 --- a/thwap/thwap-helpers.el +++ b/thwap/thwap-helpers.el @@ -33,6 +33,7 @@ LST is reversed and concatenated into a single string with line breaks." (defun thwap/ensure-directory-exists (dir) "Ensure the directory DIR exists. If not, create it." (unless (file-directory-p dir) + (message "Creating missing directory: %s" dir) (make-directory dir t))) ;; Function to list all files in a directory with a given extension diff --git a/thwap/thwap-orgmode.el b/thwap/thwap-orgmode.el index a565ce7..ca4e445 100644 --- a/thwap/thwap-orgmode.el +++ b/thwap/thwap-orgmode.el @@ -35,6 +35,7 @@ ;; base (when (memq 'orgmode thwap-orgmode) (straight-use-package 'org) + (thwap/ensure-directory-exists "~/.org-agenda") (setq browse-url-browser-function 'browse-url-generic browse-url-generic-program "firefox-esr" org-log-done 'time