From 889b0e3cae998e1b8be73092d483a9018b27fb78 Mon Sep 17 00:00:00 2001 From: James Patrick Date: Sun, 12 Feb 2023 17:53:15 -0500 Subject: [PATCH] Added mermaidjs support to orgmode --- emacs/config.org | 16 ++++++++++++++-- emacs/packages.el | 3 +++ 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/emacs/config.org b/emacs/config.org index 151adba..c110047 100644 --- a/emacs/config.org +++ b/emacs/config.org @@ -63,13 +63,18 @@ NOTE: unless you explicitly turn off the named code block will be tangled into = ** Configuration *** Lexical Bindings There [[https://nullprogram.com/blog/2016/12/22/][minor but non-zero start time benefits]] for using Lexical Bindings comments. All files created should start with - #+BEGIN_SRC emacs-lisp ;;; config.el -*- lexical-binding: t; -*- #+END_SRC replace =config.el= with the filename being loaded. +**** =packages.el= +Also go a head and add this to the =packages.el= +#+BEGIN_SRC emacs-lisp :tangle "packages.el" +;;; packages.el -*- lexical-binding: t; -*- +#+END_SRC + *** Warn user to modify =*.el= files directly. #+name:modification-warning @@ -751,9 +756,16 @@ I use =org-roam= v2 for most of my note taking. TODO expand this section. ("Goals"))))) #+end_src - **** Keybinds These were declared in [[id:f9ffe9df-a417-45c4-8bf2-6ee655140648][Roam Keybinds]] section above. See there for more details. +*** Mermaid + [[https://mermaid.js.org/][MermaidJS]] is a diagramming and charting tool similar to Dot/Graphviz, but significantly prettier with less boilerplate. We'll likely only ever want to modify it in the context of =org-mode= so we'll want [[https://github.com/arnm/ob-mermaid][ob-mermaid]]. + +Add the following the =packages.el= +#+begin_src emacs-lisp :tangle "packages.el" :noweb no-export :comments no :results output silent +(package! ob-mermaid) +#+end_src + *** Babel stuff Babel execute can be tweaked per the syntax see orgmode docs [[https://orgmode.org/manual/Evaluating-Code-Blocks.html][here]]. diff --git a/emacs/packages.el b/emacs/packages.el index e69de29..30c6370 100644 --- a/emacs/packages.el +++ b/emacs/packages.el @@ -0,0 +1,3 @@ +;;; packages.el -*- lexical-binding: t; -*- + +(package! ob-mermaid)