From 7d0e2145fd8734c23d06838e362618e0f716fbcd Mon Sep 17 00:00:00 2001 From: ndwarshuis Date: Thu, 13 Dec 2018 22:13:28 -0500 Subject: [PATCH] added org toc --- conf/main.org | 50 ++++++++++++++++++++++++++++++++++++++++++++++++ conf/org/org.org | 8 ++++++++ init.el | 2 +- 3 files changed, 59 insertions(+), 1 deletion(-) diff --git a/conf/main.org b/conf/main.org index f761709..5b3b854 100644 --- a/conf/main.org +++ b/conf/main.org @@ -18,6 +18,56 @@ The "root" is =init.el= which is the file explicitly loaded by emacs. The =init. Once loaded, the =init.el= pulls in another file called =main.el= from the =conf= directory with the function =org-babel-load-file=. =main.el= is actually sourced from an [[https://en.wikipedia.org/wiki/Org-mode][org]] file, which allows markdown and annotations surrounding each block of lisp code. Since github is awesome and understands org files as a valid markdown format, all readme files (including this one) are actually org file. After =main.el= is loaded, it may pull in a number of other files that I deemed big enough to separate (again using the =org-babel-load-file= function). Each .el/.org file that is included is stored in a separate directory under =conf=; navigate to these directories to see the file in readme format as you are reading this one. +* table of contents :TOC: +- [[#overview][overview]] + - [[#purpose-and-usage][purpose and usage]] + - [[#for-new-users][for new users]] + - [[#config-structure][config structure]] +- [[#includes][includes]] +- [[#ui][ui]] + - [[#theme][theme]] + - [[#modeline][modeline]] + - [[#clean-the-interface][clean the interface]] + - [[#other-enhancements][other enhancements]] +- [[#packages][packages]] + - [[#beacon][beacon]] + - [[#whichkey][whichkey]] + - [[#helm][helm]] + - [[#helm-swoop][helm-swoop]] + - [[#rainbow-delimiters][rainbow-delimiters]] + - [[#ace-window][ace-window]] + - [[#avy][avy]] + - [[#sudo-edit][sudo edit]] + - [[#undo-tree][undo tree]] + - [[#fill-column-indicator][fill-column-indicator]] + - [[#rainbow][rainbow]] + - [[#async][async]] + - [[#csv-mode][csv-mode]] + - [[#markdown-mode][markdown-mode]] + - [[#polymode][polymode]] +- [[#editing][editing]] + - [[#tabs-and-alignment][tabs and alignment]] + - [[#completion][completion]] + - [[#flyspell][flyspell]] + - [[#progmode][progmode]] + - [[#languages][languages]] +- [[#org-mode][org-mode]] +- [[#tools][tools]] + - [[#printing][printing]] + - [[#magit][magit]] + - [[#dired][dired]] + - [[#mu4e][mu4e]] + - [[#auctex][auctex]] + - [[#bibtex][bibtex]] + - [[#ebib][ebib]] + - [[#shell][shell]] + - [[#ediff][ediff]] +- [[#keybindings][keybindings]] + - [[#setup][setup]] + - [[#evil][evil]] + - [[#local][local]] + - [[#global][global]] + * includes These is general code that is used throughout the config file. Stored in another file for brevity. #+BEGIN_SRC emacs-lisp diff --git a/conf/org/org.org b/conf/org/org.org index 2ea8ded..b1984b3 100644 --- a/conf/org/org.org +++ b/conf/org/org.org @@ -218,6 +218,14 @@ It will clone the last entry in the selected subtree." nil (call-interactively #'nd/org-delete-subtree))) #+END_SRC +* table of contents +Since I use org mode as my config file, makes sense to have a table of contents so others can easily naviagate this crazy empire I have created :) +#+BEGIN_SRC emacs-lisp +(use-package toc-org + :ensure t + :hook + (org-mode . toc-org-mode)) +#+END_SRC * column view #+BEGIN_SRC emacs-lisp (setq org-columns-default-format diff --git a/init.el b/init.el index 91ea3c0..ce515b6 100644 --- a/init.el +++ b/init.el @@ -27,7 +27,7 @@ ;; If there is more than one, they won't work right. '(package-selected-packages (quote - (intero ebib company-math company-auctex dired-du helm-swoop org-ref helm-bibtex evil-replace-with-register evil-commentary flyspell-correct-helm helm-flyspell evil-surround markdown-mode polymode csv-mode calf-org evil-magit magit yasnippet-snippets flycheck rainbow-delimiters-mode helm evil-collection haskell-mode fill-column-indicator gtklp delight browse-kill-ring evil-org-agenda evil-org evil calfw calfw-org yaml-mode which-key use-package systemd sudo-edit spaceline rainbow-mode rainbow-delimiters pkgbuild-mode pdf-tools org-bullets lua-mode ess elpy diff-hl beacon ace-window)))) + (toc-org intero ebib company-math company-auctex dired-du helm-swoop org-ref helm-bibtex evil-replace-with-register evil-commentary flyspell-correct-helm helm-flyspell evil-surround markdown-mode polymode csv-mode calf-org evil-magit magit yasnippet-snippets flycheck rainbow-delimiters-mode helm evil-collection haskell-mode fill-column-indicator gtklp delight browse-kill-ring evil-org-agenda evil-org evil calfw calfw-org yaml-mode which-key use-package systemd sudo-edit spaceline rainbow-mode rainbow-delimiters pkgbuild-mode pdf-tools org-bullets lua-mode ess elpy diff-hl beacon ace-window)))) (custom-set-faces ;; custom-set-faces was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful.