diff --git a/.gitmodules b/.gitmodules index 16e7ed6..5a1a157 100644 --- a/.gitmodules +++ b/.gitmodules @@ -190,3 +190,6 @@ [submodule "site-lisp/plantuml-mode"] path = site-lisp/plantuml-mode url = https://github.com/skuro/plantuml-mode.git +[submodule "site-lisp/graphviz-dot-mode"] + path = site-lisp/graphviz-dot-mode + url = https://github.com/ppareit/graphviz-dot-mode.git diff --git a/lisp/init-editorconfig.el b/lisp/init-editorconfig.el index ce15141..d2a4604 100644 --- a/lisp/init-editorconfig.el +++ b/lisp/init-editorconfig.el @@ -26,7 +26,8 @@ (with-eval-after-load 'editorconfig (add-to-list 'editorconfig-indentation-alist '(js-ts-mode js-indent-level)) - (add-to-list 'editorconfig-indentation-alist '(plantuml-mode plantuml-indent-level))) + (add-to-list 'editorconfig-indentation-alist '(plantuml-mode plantuml-indent-level)) + (add-to-list 'editorconfig-indentation-alist '(graphviz-dot-mode graphviz-dot-indent-width))) (provide 'init-editorconfig) diff --git a/lisp/init-file.el b/lisp/init-file.el index 622b643..8ff703f 100644 --- a/lisp/init-file.el +++ b/lisp/init-file.el @@ -56,6 +56,10 @@ (add-to-list 'auto-mode-alist '("CMakeLists\\.txt\\'" . cmake-mode)) (add-to-list 'auto-mode-alist '("\\.cmake\\'" . cmake-mode)) +(autoload 'graphviz-dot-mode "graphviz-dot-mode" "" t) +(add-to-list 'auto-mode-alist '("\\.dot\\'" . graphviz-dot-mode)) +(add-to-list 'auto-mode-alist '("\\.gv\\'" . graphviz-dot-mode)) + ;; optimize performance of long-line files (setq-default bidi-display-reordering t) (setq bidi-inhibit-bpa t diff --git a/lisp/init-org.el b/lisp/init-org.el index 0ced56b..371d2cd 100644 --- a/lisp/init-org.el +++ b/lisp/init-org.el @@ -83,5 +83,9 @@ (with-eval-after-load 'ob-plantuml (setq org-plantuml-exec-mode 'plantuml)) +(with-eval-after-load 'org-src + (defvar org-src-lang-modes) + (add-to-list 'org-src-lang-modes '("dot" . graphviz-dot))) + (provide 'init-org) diff --git a/site-lisp/graphviz-dot-mode b/site-lisp/graphviz-dot-mode new file mode 160000 index 0000000..8ff793b --- /dev/null +++ b/site-lisp/graphviz-dot-mode @@ -0,0 +1 @@ +Subproject commit 8ff793b13707cb511875f56e167ff7f980a31136