From 8dc05f94eef71b61f105896c6d2579357c679e9f Mon Sep 17 00:00:00 2001 From: Gabriel Arazas Date: Thu, 22 Jul 2021 19:25:18 +0800 Subject: [PATCH] Update Emacs config Also updated org-roam. Though, Doom Emacs will eventually update it, rendering the custom module useless in the future. --- emacs/config.el | 4 ++-- emacs/modules/tools/wiki/config.el | 8 +------- emacs/modules/tools/wiki/packages.el | 4 ++-- emacs/templates/org-mode/__ | 4 ++-- 4 files changed, 7 insertions(+), 13 deletions(-) mode change 100644 => 100755 emacs/templates/org-mode/__ diff --git a/emacs/config.el b/emacs/config.el index e1e4c49..19f5b8e 100755 --- a/emacs/config.el +++ b/emacs/config.el @@ -19,7 +19,6 @@ projectile-project-search-path '("~/projects/software/" "~/writings/")) (setq - time-stamp-format "%Y-%02m-%02d %02H:%02M:%02S %:z" org-id-link-to-org-use-id t +file-templates-dir (expand-file-name "templates" doom-private-dir) @@ -56,7 +55,6 @@ (after! org (setq - time-stamp-start "date_modified:[ ]+\\\\?[\"<]+" org-capture-templates `( ("i" "inbox" entry (file ,(f-join org-directory "inbox.org")) @@ -92,6 +90,8 @@ (add-hook! 'before-save-hook 'time-stamp) ;; Load a custom configuration for muh wiki. +(add-hook! 'counsel-projectile-mode-hook (lambda () + (message (file-name-directory (buffer-file-name))))) (load-file (f-join +wiki-directory "config.el")) ;;; config.el ends here diff --git a/emacs/modules/tools/wiki/config.el b/emacs/modules/tools/wiki/config.el index 630c42a..d01f179 100755 --- a/emacs/modules/tools/wiki/config.el +++ b/emacs/modules/tools/wiki/config.el @@ -108,13 +108,7 @@ +anki-cards-directory (f-join +wiki-directory +anki-cards-directory-name)))) (when (featurep! +dendron) - (defvar +structured-notes-directory-name "structured") - (defvar +structured-notes-directory (f-join +wiki-directory +structured-notes-directory-name)) - (use-package! dendroam - :after org-roam - :preface (defvar +wiki-directory nil) - :config - (setq +structured-notes-directory (f-join +wiki-directory +structured-notes-directory-name)))) + :after org-roam)) ;;; config.el ends here diff --git a/emacs/modules/tools/wiki/packages.el b/emacs/modules/tools/wiki/packages.el index d733773..8e99409 100755 --- a/emacs/modules/tools/wiki/packages.el +++ b/emacs/modules/tools/wiki/packages.el @@ -3,13 +3,13 @@ ;; The main package for creating a wiki. (package! org-roam - :recipe (:host github :repo "org-roam/org-roam" :branch "v2")) + :recipe (:host github :repo "org-roam/org-roam")) (when (featurep! +biblio) (package! org-ref :recipe (:host github :repo "jkitchin/org-ref")) (package! org-roam-bibtex - :recipe (:host github :repo "org-roam/org-roam-bibtex" :branch "org-roam-v2"))) + :recipe (:host github :repo "org-roam/org-roam-bibtex"))) (when (featurep! +anki) (package! anki-editor diff --git a/emacs/templates/org-mode/__ b/emacs/templates/org-mode/__ old mode 100644 new mode 100755 index 2d82987..c75a268 --- a/emacs/templates/org-mode/__ +++ b/emacs/templates/org-mode/__ @@ -16,8 +16,8 @@ "[^[:word:]0-9]+" )) " " ) `} -#+date: "`(format-time-string "%Y-%m-%d %T %:z")`" -#+date_modified: "`(format-time-string "%Y-%m-%d %T %:z")`" +#+date: `(format-time-string "%Y-%m-%d %T %:z")` +#+date_modified: `(format-time-string "%Y-%m-%d %T %:z")` #+language: en