Org README Cleanup

- Replace top level property comment with individual tangle comments
- No tangle the org mode centering
- Make all org comments lower-case
This commit is contained in:
Sravan Balaji
2021-05-10 19:40:21 -04:00
parent 5505fbd6a6
commit 2816aff602
2 changed files with 35 additions and 42 deletions

View File

@@ -1,6 +1,5 @@
#+title: Personal Emacs Configuration #+title: Personal Emacs Configuration
#+author: Sravan Balaji #+author: Sravan Balaji
#+PROPERTY: header-args:emacs-lisp :tangle ./init.el
#+auto_tangle: t #+auto_tangle: t
* Welcome * Welcome
@@ -9,6 +8,7 @@
Run the block below with ~C-c C-c~ to tangle code blocks to config file. Run the block below with ~C-c C-c~ to tangle code blocks to config file.
*NOT IN USE*
#+begin_src emacs-lisp :tangle no #+begin_src emacs-lisp :tangle no
(org-mode-restart) (org-mode-restart)
(org-babel-tangle) (org-babel-tangle)
@@ -16,7 +16,7 @@
** Configuration Variables ** Configuration Variables
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(defvar sb/default-font-size 110) (defvar sb/default-font-size 110)
(defvar sb/default-variable-font-size 110) (defvar sb/default-variable-font-size 110)
(defvar sb/modeline-height 10) (defvar sb/modeline-height 10)
@@ -26,7 +26,7 @@
Package sources and initialization. Package sources and initialization.
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
;; Initialize package sources ;; Initialize package sources
(require 'package) (require 'package)
@@ -53,7 +53,7 @@ Package sources and initialization.
Disable some visual elements that are not necessary like startup message, scrollbar, toolbar, tooltips, menu bar, etc. Disable some visual elements that are not necessary like startup message, scrollbar, toolbar, tooltips, menu bar, etc.
Turn on the visual bell and add some breathing room. Turn on the visual bell and add some breathing room.
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(setq inhibit-startup-message t) ; Disable startup message (setq inhibit-startup-message t) ; Disable startup message
(scroll-bar-mode -1) ; Disable visible scrollbar (scroll-bar-mode -1) ; Disable visible scrollbar
@@ -68,7 +68,7 @@ Turn on the visual bell and add some breathing room.
** Line Numbers ** Line Numbers
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
;; Line Numbers ;; Line Numbers
(column-number-mode) (column-number-mode)
(global-display-line-numbers-mode t) (global-display-line-numbers-mode t)
@@ -86,7 +86,7 @@ Turn on the visual bell and add some breathing room.
Setup FiraCode and Cantarell fonts with specified size. Setup FiraCode and Cantarell fonts with specified size.
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(set-face-attribute 'default nil :font "FiraCode Nerd Font" :height sb/default-font-size) (set-face-attribute 'default nil :font "FiraCode Nerd Font" :height sb/default-font-size)
;; Set the fixed pitch face ;; Set the fixed pitch face
@@ -101,7 +101,7 @@ Setup FiraCode and Cantarell fonts with specified size.
Add ligature support for Fira Code font. Add ligature support for Fira Code font.
- https://github.com/tonsky/FiraCode/wiki/Emacs-instructions#using-ligatureel - https://github.com/tonsky/FiraCode/wiki/Emacs-instructions#using-ligatureel
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(use-package ligature (use-package ligature
:load-path "./packages/ligature.el" :load-path "./packages/ligature.el"
:config :config
@@ -130,7 +130,7 @@ Add ligature support for Fira Code font.
** General ** General
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
;; Make ESC quit prompts ;; Make ESC quit prompts
(global-set-key (kbd "<escape>") 'keyboard-escape-quit) (global-set-key (kbd "<escape>") 'keyboard-escape-quit)
@@ -154,7 +154,7 @@ Add ligature support for Fira Code font.
** Evil Keybindings ** Evil Keybindings
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
;; Evil Keybindings ;; Evil Keybindings
(use-package evil (use-package evil
:init :init
@@ -191,7 +191,7 @@ Add ligature support for Fira Code font.
** Color Theme ** Color Theme
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
;; ;; Dracula Doom Theme ;; ;; Dracula Doom Theme
;; (use-package doom-themes ;; (use-package doom-themes
;; :init (load-theme 'doom-dracula t)) ;; :init (load-theme 'doom-dracula t))
@@ -208,7 +208,7 @@ display correctly:
~M-x all-the-icons-install-fonts~ ~M-x all-the-icons-install-fonts~
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
;; Icon Fonts ;; Icon Fonts
(use-package all-the-icons) (use-package all-the-icons)
@@ -221,7 +221,7 @@ display correctly:
** Which Key ** Which Key
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(use-package which-key (use-package which-key
:init (which-key-mode) :init (which-key-mode)
:diminish which-key-mode :diminish which-key-mode
@@ -231,7 +231,7 @@ display correctly:
** Ivy and Counsel ** Ivy and Counsel
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
;; Ivy Autocompletion ;; Ivy Autocompletion
(use-package ivy (use-package ivy
:diminish :diminish
@@ -270,7 +270,7 @@ display correctly:
** Helpful Help Commands ** Helpful Help Commands
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
;; Helpful ;; Helpful
(use-package helpful (use-package helpful
:custom :custom
@@ -287,7 +287,7 @@ display correctly:
Use Hydra to design a transient key binding for quickly adjusting the scale of the text on screen. Use Hydra to design a transient key binding for quickly adjusting the scale of the text on screen.
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
;; Hydra ;; Hydra
(use-package hydra) (use-package hydra)
@@ -306,7 +306,7 @@ Use Hydra to design a transient key binding for quickly adjusting the scale of t
** Better Font Faces ** Better Font Faces
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(defun sb/org-font-setup () (defun sb/org-font-setup ()
;; Replace list hyphen with dot ;; Replace list hyphen with dot
(font-lock-add-keywords 'org-mode (font-lock-add-keywords 'org-mode
@@ -336,7 +336,7 @@ Use Hydra to design a transient key binding for quickly adjusting the scale of t
** Basic Config ** Basic Config
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(defun sb/org-mode-setup () (defun sb/org-mode-setup ()
(org-indent-mode) (org-indent-mode)
(variable-pitch-mode 1) (variable-pitch-mode 1)
@@ -467,7 +467,7 @@ Use Hydra to design a transient key binding for quickly adjusting the scale of t
*** Nicer Heading Bullets *** Nicer Heading Bullets
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(use-package org-bullets (use-package org-bullets
:after org :after org
:hook (org-mode . org-bullets-mode) :hook (org-mode . org-bullets-mode)
@@ -477,7 +477,8 @@ Use Hydra to design a transient key binding for quickly adjusting the scale of t
*** Center Org Buffers *** Center Org Buffers
#+begin_src emacs-lisp *NOT IN USE*
#+begin_src emacs-lisp :tangle no
(defun sb/org-mode-visual-fill () (defun sb/org-mode-visual-fill ()
(setq visual-fill-column-width 100 (setq visual-fill-column-width 100
visual-fill-column-center-text t) visual-fill-column-center-text t)
@@ -489,7 +490,7 @@ Use Hydra to design a transient key binding for quickly adjusting the scale of t
** Configure Babel Languages ** Configure Babel Languages
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(org-babel-do-load-languages (org-babel-do-load-languages
'org-babel-load-languages 'org-babel-load-languages
'((emacs-lisp . t) '((emacs-lisp . t)
@@ -500,7 +501,7 @@ Use Hydra to design a transient key binding for quickly adjusting the scale of t
** Structure Templates ** Structure Templates
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
;; This is needed as of Org 9.2 ;; This is needed as of Org 9.2
(require 'org-tempo) (require 'org-tempo)
@@ -515,7 +516,7 @@ Use Hydra to design a transient key binding for quickly adjusting the scale of t
Automatically tangle code blocks in file everytime it is saved. Automatically tangle code blocks in file everytime it is saved.
Add ~#+auto_tangle: t~ to the org document to enable this. Add ~#+auto_tangle: t~ to the org document to enable this.
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(use-package org-auto-tangle (use-package org-auto-tangle
:defer t :defer t
:hook (org-mode . org-auto-tangle-mode)) :hook (org-mode . org-auto-tangle-mode))
@@ -525,7 +526,7 @@ Add ~#+auto_tangle: t~ to the org document to enable this.
** Commenting ** Commenting
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(use-package evil-nerd-commenter (use-package evil-nerd-commenter
:bind ("M-/" . evilnc-comment-or-uncomment-lines)) :bind ("M-/" . evilnc-comment-or-uncomment-lines))
#+end_src #+end_src
@@ -536,43 +537,43 @@ Add ~#+auto_tangle: t~ to the org document to enable this.
**** Fish Shell **** Fish Shell
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(use-package fish-mode) (use-package fish-mode)
#+end_src #+end_src
**** Git Attributes **** Git Attributes
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(use-package gitattributes-mode) (use-package gitattributes-mode)
#+end_src #+end_src
**** Git Config **** Git Config
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(use-package gitconfig-mode) (use-package gitconfig-mode)
#+end_src #+end_src
**** Git Ignore **** Git Ignore
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(use-package gitignore-mode) (use-package gitignore-mode)
#+end_src #+end_src
**** Haskell **** Haskell
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(use-package haskell-mode) (use-package haskell-mode)
#+end_src #+end_src
**** Vimrc **** Vimrc
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(use-package vimrc-mode) (use-package vimrc-mode)
#+end_src #+end_src
*** Language Servers *** Language Servers
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(defun sb/lsp-mode-setup () (defun sb/lsp-mode-setup ()
(setq lsp-headerline-breadcrumb-segments '(path-up-to-project file symbols)) (setq lsp-headerline-breadcrumb-segments '(path-up-to-project file symbols))
(lsp-headerline-breadcrumb-mode)) (lsp-headerline-breadcrumb-mode))
@@ -598,7 +599,7 @@ Add ~#+auto_tangle: t~ to the org document to enable this.
*** Company Mode *** Company Mode
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
(use-package company (use-package company
:after lsp-mode :after lsp-mode
:hook (lsp-mode . company-mode) :hook (lsp-mode . company-mode)
@@ -617,7 +618,7 @@ Add ~#+auto_tangle: t~ to the org document to enable this.
** Projectile ** Projectile
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
;; Projectile ;; Projectile
(use-package projectile (use-package projectile
:diminish projectile-mode :diminish projectile-mode
@@ -636,7 +637,7 @@ Add ~#+auto_tangle: t~ to the org document to enable this.
** Magit ** Magit
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
;; Magit ;; Magit
(use-package magit (use-package magit
:custom :custom
@@ -659,7 +660,7 @@ Add ~#+auto_tangle: t~ to the org document to enable this.
** Rainbow Delimeters ** Rainbow Delimeters
#+begin_src emacs-lisp #+begin_src emacs-lisp :tangle init.el
;; Rainbow Delimiters ;; Rainbow Delimiters
(use-package rainbow-delimiters (use-package rainbow-delimiters
:hook (prog-mode . rainbow-delimiters-mode)) :hook (prog-mode . rainbow-delimiters-mode))

View File

@@ -365,14 +365,6 @@
:custom :custom
(org-bullets-bullet-list '("" "" "" "" "" "" ""))) (org-bullets-bullet-list '("" "" "" "" "" "" "")))
(defun sb/org-mode-visual-fill ()
(setq visual-fill-column-width 100
visual-fill-column-center-text t)
(visual-fill-column-mode 1))
(use-package visual-fill-column
:hook (org-mode . sb/org-mode-visual-fill))
(org-babel-do-load-languages (org-babel-do-load-languages
'org-babel-load-languages 'org-babel-load-languages
'((emacs-lisp . t) '((emacs-lisp . t)