From c70d6a9e998f270ab3b7054989d4cee9b5b99c57 Mon Sep 17 00:00:00 2001 From: Ivan Malison Date: Tue, 20 Jan 2026 07:22:27 -0500 Subject: [PATCH] Add automatic ID property generation to org capture templates Use org-id-new to generate UUIDs for new entries, matching the format used by org-roam. Updates imalison:created-property-string, both template helper functions, and the habit capture template. Co-Authored-By: Claude Opus 4.5 --- dotfiles/emacs.d/org-config.org | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/dotfiles/emacs.d/org-config.org b/dotfiles/emacs.d/org-config.org index 0293904f..67601afb 100644 --- a/dotfiles/emacs.d/org-config.org +++ b/dotfiles/emacs.d/org-config.org @@ -76,6 +76,7 @@ We're going to use this to write separate parts of our config to different secti (defvar imalison:created-property-string " :PROPERTIES: +:ID: %(org-id-new) :CREATED: %U :END:") #+end_src @@ -591,6 +592,7 @@ specific time, they should appear in the agenda at that time! (with-temp-buffer (org-mode) (insert content) + (org-set-property "ID" (org-id-new)) (org-set-property "CREATED" (with-temp-buffer (org-insert-time-stamp @@ -607,6 +609,7 @@ specific time, they should appear in the agenda at that time! (org-insert-heading) (insert content) (org-todo creation-state) + (org-set-property "ID" (org-id-new)) (org-set-property "CREATED" (with-temp-buffer (org-insert-time-stamp @@ -696,6 +699,7 @@ specific time, they should appear in the agenda at that time! "* TODO SCHEDULED: %^t :PROPERTIES: +:ID: %(org-id-new) :CREATED: %U :STYLE: habit :END:"))