Cleaning up Doom Emacs for DTOS.

This commit is contained in:
Derek Taylor
2021-10-18 19:38:30 -05:00
parent 79eb275052
commit 566e726b94
3 changed files with 20 additions and 99 deletions

View File

@@ -150,9 +150,6 @@
(map! :leader (map! :leader
:desc "Load new theme" "h t" #'counsel-load-theme) :desc "Load new theme" "h t" #'counsel-load-theme)
(use-package emojify
:hook (after-init . global-emojify-mode))
(use-package! elfeed-goodies) (use-package! elfeed-goodies)
(elfeed-goodies/setup) (elfeed-goodies/setup)
(setq elfeed-goodies/entry-pane-size 0.5) (setq elfeed-goodies/entry-pane-size 0.5)
@@ -199,6 +196,9 @@
:desc "Emms play previous track" "p" #'emms-previous :desc "Emms play previous track" "p" #'emms-previous
:desc "Emms play next track" "n" #'emms-next)) :desc "Emms play next track" "n" #'emms-next))
(use-package emojify
:hook (after-init . global-emojify-mode))
(map! :leader (map! :leader
(:prefix ("e". "evaluate/EWW") (:prefix ("e". "evaluate/EWW")
:desc "Evaluate elisp in buffer" "b" #'eval-buffer :desc "Evaluate elisp in buffer" "b" #'eval-buffer
@@ -257,9 +257,6 @@
:desc "Toggle line highlight globally" "H" #'global-hl-line-mode :desc "Toggle line highlight globally" "H" #'global-hl-line-mode
:desc "Toggle truncate lines" "t" #'toggle-truncate-lines)) :desc "Toggle truncate lines" "t" #'toggle-truncate-lines))
(after! mastodon
(setq mastodon-instance-url "https://distrotoot.com"))
(xterm-mouse-mode 1) (xterm-mouse-mode 1)
(after! neotree (after! neotree
@@ -280,28 +277,6 @@
:desc "Edit doom init.el" "i" #'(lambda () (interactive) (find-file "~/.config/doom/init.el")) :desc "Edit doom init.el" "i" #'(lambda () (interactive) (find-file "~/.config/doom/init.el"))
:desc "Edit doom packages.el" "p" #'(lambda () (interactive) (find-file "~/.config/doom/packages.el")))) :desc "Edit doom packages.el" "p" #'(lambda () (interactive) (find-file "~/.config/doom/packages.el"))))
(defun my/org-mode/load-prettify-symbols () "Prettify org mode keywords"
(interactive)
(setq prettify-symbols-alist
(mapcan (lambda (x) (list x (cons (upcase (car x)) (cdr x))))
'(("#+begin_src" . ?)
("#+end_src" . ?)
("#+begin_example" . ?)
("#+end_example" . ?)
("#+DATE:" . ?⏱)
("#+AUTHOR:" . ?✏)
("[ ]" . ?☐)
("[X]" . ?☑ )
("[-]" . ?❍ )
("lambda" . )
("#+header:" . ?)
("#+name:" . ?﮸)
("#+results:" . ?)
("#+call:" . ?)
(":properties:" . ?)
(":logbook:" . ?))))
(prettify-symbols-mode 1))
(map! :leader (map! :leader
:desc "Org babel tangle" "m B" #'org-babel-tangle) :desc "Org babel tangle" "m B" #'org-babel-tangle)
(after! org (after! org
@@ -383,11 +358,6 @@
:desc "Increment register" "+" #'increment-register :desc "Increment register" "+" #'increment-register
:desc "Point to register" "SPC" #'point-to-register)) :desc "Point to register" "SPC" #'point-to-register))
(map! :leader
(:prefix ("\\" . "ssh")
:desc "Ssh into distrotube.com" "\ d" #'(lambda () (interactive) (find-file "/scp:derek@distrotube.com"))
:desc "Ssh into my nextcloud" "\ n" #'(lambda () (interactive) (find-file "/scp:derek@distrotube.net"))))
(setq shell-file-name "/bin/fish" (setq shell-file-name "/bin/fish"
vterm-max-scrollback 5000) vterm-max-scrollback 5000)
(setq eshell-rc-script "~/.config/doom/eshell/profile" (setq eshell-rc-script "~/.config/doom/eshell/profile"

View File

@@ -16,9 +16,9 @@
- [[#keybindings-within-dired][Keybindings Within Dired]] - [[#keybindings-within-dired][Keybindings Within Dired]]
- [[#keybindings-within-dired-with-peep-dired-mode-enabled][Keybindings Within Dired With Peep-Dired-Mode Enabled]] - [[#keybindings-within-dired-with-peep-dired-mode-enabled][Keybindings Within Dired With Peep-Dired-Mode Enabled]]
- [[#doom-theme][DOOM THEME]] - [[#doom-theme][DOOM THEME]]
- [[#emojis][EMOJIS]]
- [[#elfeed][ELFEED]] - [[#elfeed][ELFEED]]
- [[#emms][EMMS]] - [[#emms][EMMS]]
- [[#emojis][EMOJIS]]
- [[#evaluate-elisp-expressions][EVALUATE ELISP EXPRESSIONS]] - [[#evaluate-elisp-expressions][EVALUATE ELISP EXPRESSIONS]]
- [[#eww][EWW]] - [[#eww][EWW]]
- [[#fonts][FONTS]] - [[#fonts][FONTS]]
@@ -26,14 +26,15 @@
- [[#ivy-posframe][IVY-POSFRAME]] - [[#ivy-posframe][IVY-POSFRAME]]
- [[#ivy-keybindings][IVY KEYBINDINGS]] - [[#ivy-keybindings][IVY KEYBINDINGS]]
- [[#line-settings][LINE SETTINGS]] - [[#line-settings][LINE SETTINGS]]
- [[#mastodon][MASTODON]]
- [[#mouse-support][MOUSE SUPPORT]] - [[#mouse-support][MOUSE SUPPORT]]
- [[#neotree][NEOTREE]] - [[#neotree][NEOTREE]]
- [[#open-specific-files][OPEN SPECIFIC FILES]] - [[#open-specific-files][OPEN SPECIFIC FILES]]
- [[#org-mode][ORG MODE]] - [[#org-mode][ORG MODE]]
- [[#set-font-sizes-for-each-header-level-in-org][Set font sizes for each header level in Org]]
- [[#org-export-modules][Org-Export modules]]
- [[#org-publish][Org-publish]]
- [[#password-store][PASSWORD STORE]] - [[#password-store][PASSWORD STORE]]
- [[#registers][REGISTERS]] - [[#registers][REGISTERS]]
- [[#remote-connections][REMOTE CONNECTIONS]]
- [[#shells][SHELLS]] - [[#shells][SHELLS]]
- [[#splits][SPLITS]] - [[#splits][SPLITS]]
- [[#winner-mode][WINNER MODE]] - [[#winner-mode][WINNER MODE]]
@@ -52,7 +53,7 @@ Doom Emacs uses 'SPC b' for keybindings related to bookmarks and buffers. Bookm
#+END_SRC #+END_SRC
* CALENDAR * CALENDAR
Let's make a 12-month calendar available. Nice to have so that when we click on time/date in xmobar, we get a nice 12-month calendar to view. Let's make a 12-month calendar available so we can have a calendar app that, when we click on time/date in xmobar, we get a nice 12-month calendar to view.
This is a modification of: http://homepage3.nifty.com/oatu/emacs/calendar.html This is a modification of: http://homepage3.nifty.com/oatu/emacs/calendar.html
See also: https://stackoverflow.com/questions/9547912/emacs-calendar-show-more-than-3-months See also: https://stackoverflow.com/questions/9547912/emacs-calendar-show-more-than-3-months
@@ -267,14 +268,6 @@ Setting the theme to doom-one. To try out new themes, I set a keybinding for co
:desc "Load new theme" "h t" #'counsel-load-theme) :desc "Load new theme" "h t" #'counsel-load-theme)
#+END_SRC #+END_SRC
* EMOJIS
Emojify is an Emacs extension to display emojis. It can display github style emojis like :smile: or plain ascii ones like :).
#+begin_src emacs-lisp
(use-package emojify
:hook (after-init . global-emojify-mode))
#+end_src
* ELFEED * ELFEED
An RSS newsfeed reader for Emacs. An RSS newsfeed reader for Emacs.
@@ -339,6 +332,14 @@ One of the media players available for Emacs is emms, which stands for Emacs Mul
:desc "Emms play next track" "n" #'emms-next)) :desc "Emms play next track" "n" #'emms-next))
#+END_SRC #+END_SRC
* EMOJIS
Emojify is an Emacs extension to display emojis. It can display github style emojis like :smile: or plain ascii ones like :).
#+begin_src emacs-lisp
(use-package emojify
:hook (after-init . global-emojify-mode))
#+end_src
* EVALUATE ELISP EXPRESSIONS * EVALUATE ELISP EXPRESSIONS
Changing some keybindings from their defaults to better fit with Doom Emacs, and to avoid conflicts with my window managers which sometimes use the control key in their keybindings. By default, Doom Emacs does not use 'SPC e' for anything, so I choose to use the format 'SPC e' plus 'key' for these (I also use 'SPC e' for 'eww' keybindings). Changing some keybindings from their defaults to better fit with Doom Emacs, and to avoid conflicts with my window managers which sometimes use the control key in their keybindings. By default, Doom Emacs does not use 'SPC e' for anything, so I choose to use the format 'SPC e' plus 'key' for these (I also use 'SPC e' for 'eww' keybindings).
@@ -465,14 +466,6 @@ I set comment-line to 'SPC TAB TAB' which is a rather comfortable keybinding for
:desc "Toggle truncate lines" "t" #'toggle-truncate-lines)) :desc "Toggle truncate lines" "t" #'toggle-truncate-lines))
#+END_SRC #+END_SRC
* MASTODON
Mastodon.el is a mastodon client for Emacs. Note that I wrapped my settings with (after! mastodon). Without this, my settings for the mastodon instance that I use (distrotoot.com) would be overwritten by the default settings for this module, which is "mastodon.social".
#+BEGIN_SRC emacs-lisp
(after! mastodon
(setq mastodon-instance-url "https://distrotoot.com"))
#+END_SRC
* MOUSE SUPPORT * MOUSE SUPPORT
Adding mouse support in the terminal version of Emacs. Adding mouse support in the terminal version of Emacs.
@@ -525,30 +518,6 @@ Keybindings to open files that I work with all the time using the find-file comm
* ORG MODE * ORG MODE
Note that I wrapped most of this in (after! org). Without this, my settings might be evaluated too early, which will result in my settings being overwritten by Doom's defaults. I have also enabled org-journal by adding (+journal) to the org section of my Doom Emacs init.el. Note that I wrapped most of this in (after! org). Without this, my settings might be evaluated too early, which will result in my settings being overwritten by Doom's defaults. I have also enabled org-journal by adding (+journal) to the org section of my Doom Emacs init.el.
#+begin_src emacs-lisp
(defun my/org-mode/load-prettify-symbols () "Prettify org mode keywords"
(interactive)
(setq prettify-symbols-alist
(mapcan (lambda (x) (list x (cons (upcase (car x)) (cdr x))))
'(("#+begin_src" . ?)
("#+end_src" . ?)
("#+begin_example" . ?)
("#+end_example" . ?)
("#+DATE:" . ?⏱)
("#+AUTHOR:" . ?✏)
("[ ]" . ?☐)
("[X]" . ?☑ )
("[-]" . ?❍ )
("lambda" . )
("#+header:" . ?)
("#+name:" . ?﮸)
("#+results:" . ?)
("#+call:" . ?)
(":properties:" . ?)
(":logbook:" . ?))))
(prettify-symbols-mode 1))
#+end_src
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp
(map! :leader (map! :leader
:desc "Org babel tangle" "m B" #'org-babel-tangle) :desc "Org babel tangle" "m B" #'org-babel-tangle)
@@ -583,7 +552,7 @@ Note that I wrapped most of this in (after! org). Without this, my settings mig
"CANCELLED(c)" )))) ; Task has been cancelled "CANCELLED(c)" )))) ; Task has been cancelled
#+END_SRC #+END_SRC
Setting the font sizes for each header level in Org mode. ** Set font sizes for each header level in Org
#+begin_src emacs-lisp #+begin_src emacs-lisp
(custom-set-faces (custom-set-faces
'(org-level-1 ((t (:inherit outline-1 :height 1.2)))) '(org-level-1 ((t (:inherit outline-1 :height 1.2))))
@@ -594,14 +563,15 @@ Setting the font sizes for each header level in Org mode.
) )
#+end_src #+end_src
We need ox-man for "Org eXporting" to manpage format. ** Org-Export modules
We need ox-man for "Org eXporting" to manpage format, ox-gemini for exporting to gemtext, and ox-publish for converting an Org site into an HTML site.
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp
(use-package ox-man) (use-package ox-man)
(use-package ox-gemini) (use-package ox-gemini)
(use-package ox-publish) (use-package ox-publish)
#+END_SRC #+END_SRC
Org-publish ** Org-publish
#+begin_src emacs-lisp #+begin_src emacs-lisp
(setq org-publish-use-timestamps-flag nil) (setq org-publish-use-timestamps-flag nil)
(setq org-export-with-broken-links t) (setq org-export-with-broken-links t)
@@ -623,7 +593,6 @@ Org-publish
:exclude ".*/org-html-themes/.*" :exclude ".*/org-html-themes/.*"
:publishing-function org-publish-attachment) :publishing-function org-publish-attachment)
)) ))
#+end_src #+end_src
* PASSWORD STORE * PASSWORD STORE
@@ -666,21 +635,6 @@ Emacs registers are compartments where you can save text, rectangles and positio
:desc "Point to register" "SPC" #'point-to-register)) :desc "Point to register" "SPC" #'point-to-register))
#+END_SRC #+END_SRC
* REMOTE CONNECTIONS
Keybindings for ssh'ing into remote machines. By default, Doom Emacs does not use 'SPC \', so the format I use for these bindings is 'SPC \' plus 'key'.
| DESCRIPTION | KEYBINDING |
|-------------------------+------------|
| Ssh into distrotube.com | SPC \ d |
| Ssh into my nextcloud | SPC \ n |
#+BEGIN_SRC emacs-lisp
(map! :leader
(:prefix ("\\" . "ssh")
:desc "Ssh into distrotube.com" "\ d" #'(lambda () (interactive) (find-file "/scp:derek@distrotube.com"))
:desc "Ssh into my nextcloud" "\ n" #'(lambda () (interactive) (find-file "/scp:derek@distrotube.net"))))
#+END_SRC
* SHELLS * SHELLS
Settings for the various shells and terminal emulators within Emacs. Settings for the various shells and terminal emulators within Emacs.
+ 'shell-file-name' -- sets the shell to be used in M-x shell, M-x term, M-x ansi-term and M-x vterm. + 'shell-file-name' -- sets the shell to be used in M-x shell, M-x term, M-x ansi-term and M-x vterm.

View File

@@ -59,10 +59,7 @@
(package! elpher) (package! elpher)
(package! emojify) (package! emojify)
(package! evil-tutor) (package! evil-tutor)
(package! exwm)
(package! hyperbole)
(package! ivy-posframe) (package! ivy-posframe)
(package! mastodon)
(package! org-bullets) (package! org-bullets)
(package! ox-gemini) (package! ox-gemini)
(package! peep-dired) (package! peep-dired)