Commit 8219e41ec14c

Vincent Demeester <vincent@sbr.pm>
2025-05-06 09:48:04
tools/emacs: move to one TODO file and update some configurations
- Remove work and personal files - Remove future-file (not used anymore) - Update agenda-files and refile-targets Signed-off-by: Vincent Demeester <vincent@sbr.pm>
1 parent 91bf666
Changed files (1)
tools
emacs
tools/emacs/config/config-org.el
@@ -12,20 +12,15 @@
   "org-mode notes directory, for notes, managed by denote")
 (defconst org-inbox-file (expand-file-name "inbox.org" org-directory)
   "New stuff collected in this file.")
-(defconst org-work-file (expand-file-name "work.org" org-directory)
-  "New stuff collected in this file.")
-(defconst org-personal-file (expand-file-name "personal.org" org-directory)
-  "New stuff collected in this file.")
+(defconst org-todos-file (expand-file-name "todos.org" org-directory)
+  "TODOs collected in this file.")
 ;; I am not using this too much
-(defconst org-remember-file (expand-file-name "rembmer.org" org-directory)
+(defconst org-remember-file (expand-file-name "remember.org" org-directory)
   "Remember file, very quick and dirty scratch notes, to be refiled later on.")
 
 (defconst org-archive-dir (expand-file-name "archive" org-directory)
   "Directory of archived files.")
 
-;; FIXME move this file
-(defconst org-projects-future-file (expand-file-name "20231120T124316--future-projects-incubation__project_future.org" org-notes-directory)
-  "Future projects are collected in this file.")
 (defconst org-people-dir (expand-file-name "people" org-notes-directory)
   "People files directory.")
 
@@ -36,9 +31,7 @@
   "Org babel library.")
 
 (set-register ?i `(file . ,org-inbox-file))
-(set-register ?w `(file . ,org-work-file))
-(set-register ?p `(file . ,org-personal-file))
-(set-register ?f `(file . ,org-projects-future-file))
+(set-register ?t `(file . ,org-todos-file))
 (set-register ?o `(file . ,org-directory))
 (set-register ?P `(file . ,org-people-dir))
 
@@ -129,14 +122,19 @@
   (org-outline-path-complete-in-steps nil)
   (org-goto-max-level 2)
 
-  (org-agenda-category-icon-alist `(("journal"  ,(list (propertize "๐Ÿ“")))
+  (org-agenda-category-icon-alist `(("personal"  ,(list (propertize "๐Ÿก")))
+				    ("work"  ,(list (propertize "๐Ÿข")))
+				    ("appointments"  ,(list (propertize "๐Ÿ“…")))
+				    ("health"  ,(list (propertize "โš•๏ธ")))
+				    ("systems"  ,(list (propertize "๐Ÿ–ฅ๏ธ")))
+				    ("journal"  ,(list (propertize "๐Ÿ“")))
 				    ("project--" ,(list (propertize "๐Ÿ’ผ" )))
 				    ("tekton", (list (propertize "๐Ÿ˜ผ")))
 				    ("openshift-pipelines", (list (propertize "๐ŸŽฉ")))
 				    ("redhat", (list (propertize "๐ŸŽฉ")))
 				    ("area--"  ,(list (propertize"๐Ÿข" )))
-				    ("area--home"  ,(list (propertize"๐Ÿก" )))
-				    ("home"  ,(list (propertize"๐Ÿก" )))
+				    ("area--home"  ,(list (propertize "๐Ÿก")))
+				    ("home"  ,(list (propertize "๐Ÿก")))
 				    ("home-services" ,(list (propertize "โ˜• ")))
 				    ("email"  ,(list (propertize"๐Ÿ“จ" )))
 				    ("people"  ,(list (propertize"๐Ÿ‘ค" )))
@@ -187,12 +185,17 @@
 	     (--remove (s-starts-with? "." it))
 	     (--map (format "%s/%s" org-directory it))
 	     (--map `(,it :maxlevel . 3)))
+	    (->>
+	     (directory-files org-notes-directory nil ".org$")
+	     (--remove (s-starts-with? "." it))
+	     (--map (format "%s/%s" org-note-sdirectory it))
+	     (--map `(,it :maxlevel . 3)))
 	    (->>
 	     (directory-files-recursively org-people-dir ".org$")
 	     (--remove (s-starts-with? (format "%s/legacy" org-people-dir) it))
 	     (--map (format "%s" it))
 	     (--map `(,it :maxlevel . 3)))))
-  (setq org-agenda-files `(,org-inbox-file ,org-work-file ,org-personal-file)
+  (setq org-agenda-files `(,org-inbox-file ,org-todos-file)
 	;; TODO: extract org-refile-targets into a function
 	org-refile-targets (vde/org-refile-targets))
   (setq org-agenda-custom-commands