updated doom emacs config

This commit is contained in:
Clay Gomera 2023-05-27 00:53:44 -04:00
parent 3965532bcf
commit edb806e569
5 changed files with 271 additions and 364 deletions

View file

@ -80,26 +80,6 @@
(use-package! calfw) (use-package! calfw)
(use-package! calfw-org) (use-package! calfw-org)
(setq centaur-tabs-set-bar 'over
centaur-tabs-set-icons t
centaur-tabs-gray-out-icons 'buffer
centaur-tabs-height 24
centaur-tabs-set-modified-marker t
centaur-tabs-style "bar"
centaur-tabs-modified-marker "")
(map! :leader
:desc "Toggle tabs globally" "t c" #'centaur-tabs-mode
:desc "Toggle tabs local display" "t C" #'centaur-tabs-local-mode)
(evil-define-key 'normal centaur-tabs-mode-map (kbd "g <right>") 'centaur-tabs-forward ; default Doom binding is 'g t'
(kbd "g <left>") 'centaur-tabs-backward ; default Doom binding is 'g T'
(kbd "g <down>") 'centaur-tabs-forward-group
(kbd "g <up>") 'centaur-tabs-backward-group)
(map! :leader
(:prefix ("c h" . "Help info from Clippy")
:desc "Clippy describes function under point" "f" #'clippy-describe-function
:desc "Clippy describes variable under point" "v" #'clippy-describe-variable))
(use-package dashboard (use-package dashboard
:init ;; tweak dashboard config before loading it :init ;; tweak dashboard config before loading it
(setq dashboard-set-heading-icons t) (setq dashboard-set-heading-icons t)
@ -180,73 +160,9 @@ List of keybindings (SPC h b b)")
(map! :leader (map! :leader
:desc "Load new theme" "h t" #'counsel-load-theme) :desc "Load new theme" "h t" #'counsel-load-theme)
(use-package! elfeed-goodies)
(elfeed-goodies/setup)
(setq elfeed-goodies/entry-pane-size 0.5)
(add-hook 'elfeed-show-mode-hook 'visual-line-mode)
(evil-define-key 'normal elfeed-show-mode-map
(kbd "J") 'elfeed-goodies/split-show-next
(kbd "K") 'elfeed-goodies/split-show-prev)
(evil-define-key 'normal elfeed-search-mode-map
(kbd "J") 'elfeed-goodies/split-show-next
(kbd "K") 'elfeed-goodies/split-show-prev)
(setq elfeed-feeds (quote
(("https://www.reddit.com/r/linux.rss" reddit linux)
("https://www.reddit.com/r/commandline.rss" reddit commandline)
("https://www.reddit.com/r/distrotube.rss" reddit distrotube)
("https://www.reddit.com/r/emacs.rss" reddit emacs)
("https://www.gamingonlinux.com/article_rss.php" gaming linux)
("https://hackaday.com/blog/feed/" hackaday linux)
("https://opensource.com/feed" opensource linux)
("https://linux.softpedia.com/backend.xml" softpedia linux)
("https://itsfoss.com/feed/" itsfoss linux)
("https://www.zdnet.com/topic/linux/rss.xml" zdnet linux)
("https://www.phoronix.com/rss.php" phoronix linux)
("http://feeds.feedburner.com/d0od" omgubuntu linux)
("https://www.computerworld.com/index.rss" computerworld linux)
("https://www.networkworld.com/category/linux/index.rss" networkworld linux)
("https://www.techrepublic.com/rssfeeds/topic/open-source/" techrepublic linux)
("https://betanews.com/feed" betanews linux)
("http://lxer.com/module/newswire/headlines.rss" lxer linux)
("https://archlinux.org/feeds/news/" arch linux)
("https://distrowatch.com/news/dwd.xml" distrowatch linux))))
(emms-all)
(emms-default-players)
(emms-mode-line 1)
(emms-playing-time 1)
(setq emms-source-file-default-directory "~/Music/"
emms-playlist-buffer-name "*Music*"
emms-info-asynchronously t
emms-source-file-directory-tree-function 'emms-source-file-directory-tree-find)
(map! :leader
(:prefix ("a" . "EMMS audio player")
:desc "Go to emms playlist" "a" #'emms-playlist-mode-go
:desc "Emms pause track" "x" #'emms-pause
:desc "Emms stop track" "s" #'emms-stop
:desc "Emms play previous track" "p" #'emms-previous
:desc "Emms play next track" "n" #'emms-next))
(use-package emojify (use-package emojify
:hook (after-init . global-emojify-mode)) :hook (after-init . global-emojify-mode))
(map! :leader
(:prefix ("e". "evaluate/ERC/EWW")
:desc "Launch ERC with TLS connection" "E" #'erc-tls))
(setq erc-prompt (lambda () (concat "[" (buffer-name) "]"))
erc-server "irc.libera.chat"
erc-nick "distrotube"
erc-user-full-name "Derek Taylor"
erc-track-shorten-start 24
erc-autojoin-channels-alist '(("irc.libera.chat" "#archlinux" "#linux" "#emacs"))
erc-kill-buffer-on-part t
erc-fill-column 100
erc-fill-function 'erc-fill-static
erc-fill-static-center 20
;; erc-auto-query 'bury
)
(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
@ -273,6 +189,16 @@ List of keybindings (SPC h b b)")
'(font-lock-comment-face :slant italic) '(font-lock-comment-face :slant italic)
'(font-lock-keyword-face :slant italic)) '(font-lock-keyword-face :slant italic))
(setq imenu-list-focus-after-activation t)
(map! :leader
(:prefix ("s" . "Search")
:desc "Menu to jump to places in buffer" "i" #'counsel-imenu))
(map! :leader
(:prefix ("t" . "Toggle")
:desc "Toggle imenu shown in a sidebar" "i" #'imenu-list-smart-toggle))
(defun dt/insert-todays-date (prefix) (defun dt/insert-todays-date (prefix)
(interactive "P") (interactive "P")
(let ((format (cond (let ((format (cond
@ -577,8 +503,6 @@ List of keybindings (SPC h b b)")
:config :config
(setq org-auto-tangle-default t)) (setq org-auto-tangle-default t))
(use-package! password-store)
(map! :leader (map! :leader
:desc "Switch to perspective NAME" "DEL" #'persp-switch :desc "Switch to perspective NAME" "DEL" #'persp-switch
:desc "Switch to buffer in perspective" "," #'persp-switch-to-buffer :desc "Switch to buffer in perspective" "," #'persp-switch-to-buffer
@ -605,7 +529,7 @@ List of keybindings (SPC h b b)")
: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))
(setq shell-file-name "/bin/fish" (setq shell-file-name "/bin/bash"
vterm-max-scrollback 5000) vterm-max-scrollback 5000)
(setq eshell-rc-script "~/.config/doom/eshell/profile" (setq eshell-rc-script "~/.config/doom/eshell/profile"
eshell-aliases-file "~/.config/doom/eshell/aliases" eshell-aliases-file "~/.config/doom/eshell/aliases"
@ -637,8 +561,5 @@ List of keybindings (SPC h b b)")
:desc "Zap to char" "z" #'zap-to-char :desc "Zap to char" "z" #'zap-to-char
:desc "Zap up to char" "Z" #'zap-up-to-char) :desc "Zap up to char" "Z" #'zap-up-to-char)
(setq mastodon-instance-url "https://fosstodon.org" (set-frame-parameter (selected-frame) 'alpha '(98 . 80))
mastodon-active-user "d4r1us-drk") (add-to-list 'default-frame-alist '(alpha . (98 . 80)))
(set-frame-parameter (selected-frame) 'alpha '(95 . 80))
(add-to-list 'default-frame-alist '(alpha . (95 . 80)))

View file

@ -5,75 +5,79 @@
#+PROPERTY: header-args :tangle config.el #+PROPERTY: header-args :tangle config.el
* TABLE OF CONTENTS :toc: * TABLE OF CONTENTS :toc:
- [[#about-this-config][ABOUT THIS CONFIG]] - [[#about-this-config][About this config]]
- [[#beacon][BEACON]] - [[#beacon][Beacon]]
- [[#bookmarks-and-buffers][BOOKMARKS AND BUFFERS]] - [[#bookmarks-and-buffers][Bookmarks and buffers]]
- [[#bookmarks][Bookmarks]] - [[#bookmarks][Bookmarks]]
- [[#buffers][Buffers]] - [[#buffers][Buffers]]
- [[#global-auto-revert][Global Auto Revert]] - [[#global-auto-revert][Global Auto Revert]]
- [[#keybindings-within-ibuffer-mode][Keybindings within ibuffer mode]] - [[#keybindings-within-ibuffer-mode][Keybindings within ibuffer mode]]
- [[#calendar][CALENDAR]] - [[#calendar][Calendar]]
- [[#centaur-tabs][CENTAUR-TABS]] - [[#dashboard][Dashboard]]
- [[#clippy][CLIPPY]]
- [[#dashboard][DASHBOARD]]
- [[#configuring-dashboard][Configuring Dashboard]] - [[#configuring-dashboard][Configuring Dashboard]]
- [[#dashboard-in-emacsclient][Dashboard in Emacsclient]] - [[#dashboard-in-emacsclient][Dashboard in Emacsclient]]
- [[#dired][DIRED]] - [[#dired][Dired]]
- [[#keybindings-to-open-dired][Keybindings To Open Dired]] - [[#keybindings-to-open-dired][Keybindings To Open Dired]]
- [[#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]]
- [[#making-deleted-files-go-to-trash-can][Making deleted files go to trash can]] - [[#making-deleted-files-go-to-trash-can][Making deleted files go to trash can]]
- [[#doom-theme][DOOM THEME]] - [[#doom-theme][Doom theme]]
- [[#elfeed][ELFEED]] - [[#emojis][Emojis]]
- [[#emms][EMMS]] - [[#evaluate-elisp-expressions][Evaluate elisp expressions]]
- [[#emojis][EMOJIS]] - [[#eww][Eww]]
- [[#erc][ERC]] - [[#fonts][Fonts]]
- [[#evaluate-elisp-expressions][EVALUATE ELISP EXPRESSIONS]] - [[#imenu][Imenu]]
- [[#eww][EWW]] - [[#insert-date][Insert date]]
- [[#fonts][FONTS]] - [[#ivy][Ivy]]
- [[#insert-date][INSERT DATE]] - [[#ivy-posframe][Ivy-posframe]]
- [[#ivy][IVY]] - [[#ivy-keybindings][Ivy keybindings]]
- [[#ivy-posframe][IVY-POSFRAME]] - [[#line-settings][Line settings]]
- [[#ivy-keybindings][IVY KEYBINDINGS]] - [[#markdown][Markdown]]
- [[#line-settings][LINE SETTINGS]] - [[#minimap][Minimap]]
- [[#markdown][MARKDOWN]] - [[#modeline][Modeline]]
- [[#minimap][MINIMAP]] - [[#mouse-support][Mouse support]]
- [[#modeline][MODELINE]] - [[#neotree][Neotree]]
- [[#mouse-support][MOUSE SUPPORT]] - [[#open-specific-files][Open specific files]]
- [[#neotree][NEOTREE]] - [[#org-mode][Org mode]]
- [[#open-specific-files][OPEN SPECIFIC FILES]]
- [[#org-mode][ORG MODE]]
- [[#org-fonts][Org fonts]] - [[#org-fonts][Org fonts]]
- [[#org-export][Org-export]] - [[#org-export][Org-export]]
- [[#org-journal][Org-journal]] - [[#org-journal][Org-journal]]
- [[#org-publish][Org-publish]] - [[#org-publish][Org-publish]]
- [[#org-auto-tangle][Org-auto-tangle]] - [[#org-auto-tangle][Org-auto-tangle]]
- [[#password-store][PASSWORD STORE]] - [[#perspective][Perspective]]
- [[#perspective][PERSPECTIVE]] - [[#rainbow-mode][Rainbow mode]]
- [[#rainbow-mode][RAINBOW MODE]] - [[#registers][Registers]]
- [[#registers][REGISTERS]] - [[#shells][Shells]]
- [[#shells][SHELLS]] - [[#splits][Splits]]
- [[#splits][SPLITS]] - [[#winner-mode][Winner mode]]
- [[#winner-mode][WINNER MODE]] - [[#zap-to-char][Zap to char]]
- [[#zap-to-char][ZAP TO CHAR]] - [[#transparency][Transparency]]
- [[#mastodon][MASTODON]]
- [[#transparency][TRANSPARENCY]]
* ABOUT THIS CONFIG * About this config
This is my personal Doom Emacs config. Doom Emacs is a distribution of Emacs that uses the "evil" keybindings (Vim keybindings) and includes a number of nice extensions and a bit of configuration out of the box. I am maintaining this config not just for myself, but also for those that want to explore some of what is possible with Emacs. I will add a lot of examples of plugins and settings, some of them I may not even use personally. I do this because many people following me on YouTube look at my configs as "documentation". This config is a fork of DistroTube's config. This is my personal Doom Emacs config. Doom Emacs is a distribution of Emacs
that uses the "evil" keybindings (Vim keybindings) and includes a number of nice
extensions and a bit of configuration out of the box. I am maintaining this
config not just for myself, but also for those that want to explore some of what
is possible with Emacs. I will add a lot of examples of plugins and settings,
some of them I may not even use personally. This config is a fork of
DistroTube's config.
* BEACON * Beacon
Never lose your cursor. When you scroll, your cursor will shine! This is a global minor-mode. Turn it on everywhere with: Never lose your cursor. When you scroll, your cursor will shine! This is a
global minor-mode. Turn it on everywhere with:
#+begin_src emacs-lisp #+begin_src emacs-lisp
(beacon-mode 1) (beacon-mode 1)
#+end_src #+end_src
* BOOKMARKS AND BUFFERS * Bookmarks and buffers
Doom Emacs uses 'SPC b' for keybindings related to bookmarks and buffers. Doom Emacs uses 'SPC b' for keybindings related to bookmarks and buffers.
** Bookmarks ** Bookmarks
Bookmarks are somewhat like registers in that they record positions you can jump to. Unlike registers, they have long names, and they persist automatically from one Emacs session to the next. The prototypical use of bookmarks is to record where you were reading in various files. Bookmarks are somewhat like registers in that they record positions you can jump
to. Unlike registers, they have long names, and they persist automatically from
one Emacs session to the next. The prototypical use of bookmarks is to record
where you were reading in various files.
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp
(map! :leader (map! :leader
@ -83,7 +87,11 @@ Bookmarks are somewhat like registers in that they record positions you can jump
#+END_SRC #+END_SRC
** Buffers ** Buffers
Regarding /buffers/, the text you are editing in Emacs resides in an object called a /buffer/. Each time you visit a file, a buffer is used to hold the files text. Each time you invoke Dired, a buffer is used to hold the directory listing. /Ibuffer/ is a program that lists all of your Emacs /buffers/, allowing you to navigate between them and filter them. Regarding /buffers/, the text you are editing in Emacs resides in an object called
a /buffer/. Each time you visit a file, a buffer is used to hold the files text.
Each time you invoke Dired, a buffer is used to hold the directory listing.
/Ibuffer/ is a program that lists all of your Emacs /buffers/, allowing you to
navigate between them and filter them.
| COMMAND | DESCRIPTION | KEYBINDING | | COMMAND | DESCRIPTION | KEYBINDING |
|-----------------+----------------------+------------| |-----------------+----------------------+------------|
@ -94,7 +102,11 @@ Regarding /buffers/, the text you are editing in Emacs resides in an object call
| save-buffer | Save current buffer | SPC b s | | save-buffer | Save current buffer | SPC b s |
** Global Auto Revert ** Global Auto Revert
A buffer can get out of sync with respect to its visited file on disk if that file is changed by another program. To keep it up to date, you can enable Auto Revert mode by typing M-x auto-revert-mode, or you can set it to be turned on globally with 'global-auto-revert-mode'. I have also turned on Global Auto Revert on non-file buffers, which is especially useful for 'dired' buffers. A buffer can get out of sync with respect to its visited file on disk if that
file is changed by another program. To keep it up to date, you can enable Auto
Revert mode by typing M-x auto-revert-mode, or you can set it to be turned on
globally with 'global-auto-revert-mode'. I have also turned on Global Auto
Revert on non-file buffers, which is especially useful for 'dired' buffers.
#+begin_src emacs-lisp #+begin_src emacs-lisp
(global-auto-revert-mode 1) (global-auto-revert-mode 1)
@ -128,8 +140,9 @@ A buffer can get out of sync with respect to its visited file on disk if that fi
(kbd "g H") 'ibuffer-update) (kbd "g H") 'ibuffer-update)
#+end_src #+end_src
* CALENDAR * Calendar
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. 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
@ -201,52 +214,9 @@ Let's also play around with calfw.
(use-package! calfw-org) (use-package! calfw-org)
#+end_src #+end_src
* CENTAUR-TABS * Dashboard
To use tabs in Doom Emacs, be sure to uncomment "tabs" in Doom's init.el. Displays tabs at the top of the window similar to tabbed web browsers such as Firefox. I don't actually use tabs in Emacs. I placed this in my config to help others who may want tabs. In the default configuration of Doom Emacs, 'SPC t' is used for "toggle" keybindings, so I choose 'SPC t c' to toggle centaur-tabs. The "g" prefix for keybindings is used for a bunch of evil keybindings in Doom, but "g" plus the arrow keys were not used, so I thought I would bind those for tab navigation. But I did leave the default "g t" and "g T" intact if you prefer to use those for centaur-tabs-forward/backward. Emacs Dashboard is an extensible startup screen showing you recent files,
bookmarks, agenda items and an Emacs banner.
| COMMAND | DESCRIPTION | KEYBINDING |
|-----------------------------+---------------------------+------------------|
| centaur-tabs-mode | /Toggle tabs globally/ | SPC t c |
| centaur-tabs-local-mode | /Toggle tabs local display/ | SPC t C |
| centaur-tabs-forward | /Next tab/ | g <right> or g t |
| centaur-tabs-backward | /Previous tab/ | g <left> or g T |
| centaur-tabs-forward-group | /Next tab group/ | g <down> |
| centaur-tabs-backward-group | /Previous tab group/ | g <up> |
#+BEGIN_SRC emacs-lisp
(setq centaur-tabs-set-bar 'over
centaur-tabs-set-icons t
centaur-tabs-gray-out-icons 'buffer
centaur-tabs-height 24
centaur-tabs-set-modified-marker t
centaur-tabs-style "bar"
centaur-tabs-modified-marker "•")
(map! :leader
:desc "Toggle tabs globally" "t c" #'centaur-tabs-mode
:desc "Toggle tabs local display" "t C" #'centaur-tabs-local-mode)
(evil-define-key 'normal centaur-tabs-mode-map (kbd "g <right>") 'centaur-tabs-forward ; default Doom binding is 'g t'
(kbd "g <left>") 'centaur-tabs-backward ; default Doom binding is 'g T'
(kbd "g <down>") 'centaur-tabs-forward-group
(kbd "g <up>") 'centaur-tabs-backward-group)
#+END_SRC
* CLIPPY
Gives us a popup box with "Clippy, the paper clip". You can make him say various things by calling 'clippy-say' function. But the more useful functions of clippy are the two describe functions provided: 'clippy-describe-function' and 'clippy-describe-variable'. Hit the appropriate keybinding while the point is over a function/variable to call it. A popup with helpful clippy will appear, telling you about the function/variable (using describe-function and describe-variable respectively).
| COMMAND | DESCRIPTION | KEYBINDING |
|--------------------------+---------------------------------------+------------|
| clippy-describe-function | /Clippy describes function under point/ | SPC c h f |
| clippy-describe-variable | /Clippy describes variable under point/ | SPC c h v |
#+begin_src emacs-lisp
(map! :leader
(:prefix ("c h" . "Help info from Clippy")
:desc "Clippy describes function under point" "f" #'clippy-describe-function
:desc "Clippy describes variable under point" "v" #'clippy-describe-variable))
#+end_src
* DASHBOARD
Emacs Dashboard is an extensible startup screen showing you recent files, bookmarks, agenda items and an Emacs banner.
** Configuring Dashboard ** Configuring Dashboard
#+begin_src emacs-lisp #+begin_src emacs-lisp
@ -282,8 +252,10 @@ This setting ensures that emacsclient always opens on *dashboard* rather than *s
(setq doom-fallback-buffer "*dashboard*") (setq doom-fallback-buffer "*dashboard*")
#+end_src #+end_src
* DIRED * Dired
Dired is the file manager within Emacs. Below, I setup keybindings for image previews (peep-dired). Doom Emacs does not use 'SPC d' for any of its keybindings, so I've chosen the format of 'SPC d' plus 'key'. Dired is the file manager within Emacs. Below, I setup keybindings for image
previews (peep-dired). Doom Emacs does not use 'SPC d' for any of its
keybindings, so I've chosen the format of 'SPC d' plus 'key'.
** Keybindings To Open Dired ** Keybindings To Open Dired
@ -374,7 +346,8 @@ Dired is the file manager within Emacs. Below, I setup keybindings for image pr
#+end_src #+end_src
** Keybindings Within Dired With Peep-Dired-Mode Enabled ** Keybindings Within Dired With Peep-Dired-Mode Enabled
If peep-dired is enabled, you will get image previews as you go up/down with 'j' and 'k' If peep-dired is enabled, you will get image previews as you go up/down with 'j'
and 'k'
| COMMAND | DESCRIPTION | KEYBINDING | | COMMAND | DESCRIPTION | KEYBINDING |
|----------------------+------------------------------------------+------------| |----------------------+------------------------------------------+------------|
@ -395,8 +368,9 @@ If peep-dired is enabled, you will get image previews as you go up/down with 'j'
trash-directory "~/.local/share/Trash/files/") trash-directory "~/.local/share/Trash/files/")
#+end_src #+end_src
* DOOM THEME * Doom theme
Setting the theme to doom-one. To try out new themes, I set a keybinding for counsel-load-theme with 'SPC h t'. Setting the theme to doom-gruvbox. To try out new themes, I set a keybinding for
counsel-load-theme with 'SPC h t'.
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp
(setq doom-theme 'doom-gruvbox) (setq doom-theme 'doom-gruvbox)
@ -404,107 +378,21 @@ 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
* ELFEED * Emojis
An RSS newsfeed reader for Emacs. 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! elfeed-goodies)
(elfeed-goodies/setup)
(setq elfeed-goodies/entry-pane-size 0.5)
(add-hook 'elfeed-show-mode-hook 'visual-line-mode)
(evil-define-key 'normal elfeed-show-mode-map
(kbd "J") 'elfeed-goodies/split-show-next
(kbd "K") 'elfeed-goodies/split-show-prev)
(evil-define-key 'normal elfeed-search-mode-map
(kbd "J") 'elfeed-goodies/split-show-next
(kbd "K") 'elfeed-goodies/split-show-prev)
(setq elfeed-feeds (quote
(("https://www.reddit.com/r/linux.rss" reddit linux)
("https://www.reddit.com/r/commandline.rss" reddit commandline)
("https://www.reddit.com/r/distrotube.rss" reddit distrotube)
("https://www.reddit.com/r/emacs.rss" reddit emacs)
("https://www.gamingonlinux.com/article_rss.php" gaming linux)
("https://hackaday.com/blog/feed/" hackaday linux)
("https://opensource.com/feed" opensource linux)
("https://linux.softpedia.com/backend.xml" softpedia linux)
("https://itsfoss.com/feed/" itsfoss linux)
("https://www.zdnet.com/topic/linux/rss.xml" zdnet linux)
("https://www.phoronix.com/rss.php" phoronix linux)
("http://feeds.feedburner.com/d0od" omgubuntu linux)
("https://www.computerworld.com/index.rss" computerworld linux)
("https://www.networkworld.com/category/linux/index.rss" networkworld linux)
("https://www.techrepublic.com/rssfeeds/topic/open-source/" techrepublic linux)
("https://betanews.com/feed" betanews linux)
("http://lxer.com/module/newswire/headlines.rss" lxer linux)
("https://archlinux.org/feeds/news/" arch linux)
("https://distrowatch.com/news/dwd.xml" distrowatch linux))))
#+END_SRC
* EMMS
One of the media players available for Emacs is emms, which stands for Emacs Multimedia System. By default, Doom Emacs does not use 'SPC a',' so the format I use for these bindings is 'SPC a' plus 'key'.
| COMMAND | DESCRIPTION | KEYBINDING |
|-----------------------+-----------------------------------+------------|
| emms-playlist-mode-go | /Switch to the playlist buffer/ | SPC a a |
| emms-pause | /Pause the track/ | SPC a x |
| emms-stop | /Stop the track/ | SPC a s |
| emms-previous | /Play previous track in playlist/ | SPC a p |
| emms-next | /Play next track in playlist/ | SPC a n |
#+BEGIN_SRC emacs-lisp
(emms-all)
(emms-default-players)
(emms-mode-line 1)
(emms-playing-time 1)
(setq emms-source-file-default-directory "~/Music/"
emms-playlist-buffer-name "*Music*"
emms-info-asynchronously t
emms-source-file-directory-tree-function 'emms-source-file-directory-tree-find)
(map! :leader
(:prefix ("a" . "EMMS audio player")
:desc "Go to emms playlist" "a" #'emms-playlist-mode-go
:desc "Emms pause track" "x" #'emms-pause
:desc "Emms stop track" "s" #'emms-stop
:desc "Emms play previous track" "p" #'emms-previous
:desc "Emms play next track" "n" #'emms-next))
#+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 #+begin_src emacs-lisp
(use-package emojify (use-package emojify
:hook (after-init . global-emojify-mode)) :hook (after-init . global-emojify-mode))
#+end_src #+end_src
* ERC * Evaluate elisp expressions
ERC is a built-in Emacs IRC client. 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
| COMMAND | DESCRIPTION | KEYBINDING | 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'
| erc-tls | /Launch ERC using more secure TLS connection/ | SPC e E | for 'eww' keybindings).
#+begin_src emacs-lisp
(map! :leader
(:prefix ("e". "evaluate/ERC/EWW")
:desc "Launch ERC with TLS connection" "E" #'erc-tls))
(setq erc-prompt (lambda () (concat "[" (buffer-name) "]"))
erc-server "irc.libera.chat"
erc-nick "distrotube"
erc-user-full-name "Derek Taylor"
erc-track-shorten-start 24
erc-autojoin-channels-alist '(("irc.libera.chat" "#archlinux" "#linux" "#emacs"))
erc-kill-buffer-on-part t
erc-fill-column 100
erc-fill-function 'erc-fill-static
erc-fill-static-center 20
;; erc-auto-query 'bury
)
#+end_src
* 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).
| COMMAND | DESCRIPTION | KEYBINDING | | COMMAND | DESCRIPTION | KEYBINDING |
|-----------------+----------------------------------------------+------------| |-----------------+----------------------------------------------+------------|
@ -524,8 +412,13 @@ Changing some keybindings from their defaults to better fit with Doom Emacs, and
:desc "Evaluate elisp in region" "r" #'eval-region)) :desc "Evaluate elisp in region" "r" #'eval-region))
#+END_SRC #+END_SRC
* EWW * Eww
EWW is the Emacs Web Wowser, the builtin browser in Emacs. Below I set urls to open in a specific browser (eww) with browse-url-browser-function. 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 'eval' keybindings). I chose to use 'SPC s w' for eww-search-words because Doom Emacs uses 'SPC s' for 'search' commands. EWW is the Emacs Web Wowser, the builtin browser in Emacs. Below I set urls to
open in a specific browser (eww) with browse-url-browser-function. 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 'eval' keybindings). I chose to
use 'SPC s w' for eww-search-words because Doom Emacs uses 'SPC s' for 'search'
commands.
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp
(setq browse-url-browser-function 'eww-browse-url) (setq browse-url-browser-function 'eww-browse-url)
@ -537,7 +430,7 @@ EWW is the Emacs Web Wowser, the builtin browser in Emacs. Below I set urls to
:desc "Eww reload page" "R" #'eww-reload)) :desc "Eww reload page" "R" #'eww-reload))
#+END_SRC #+END_SRC
* FONTS * Fonts
Settings related to fonts within Doom Emacs: Settings related to fonts within Doom Emacs:
+ 'doom-font' -- standard monospace font that is used for most things in Emacs. + 'doom-font' -- standard monospace font that is used for most things in Emacs.
+ 'doom-variable-pitch-font' -- variable font which is useful in some Emacs plugins. + 'doom-variable-pitch-font' -- variable font which is useful in some Emacs plugins.
@ -557,8 +450,38 @@ Settings related to fonts within Doom Emacs:
'(font-lock-keyword-face :slant italic)) '(font-lock-keyword-face :slant italic))
#+END_SRC #+END_SRC
* INSERT DATE * Imenu
Some custom functions to insert the date. The function 'insert-todays-date' can be used one of three different ways: (1) just the keybinding without the universal argument prefix, (2) with one universal argument prefix, or (3) with two universal argument prefixes. The universal argument prefix is 'SPC-u' in Doom Emacs (C-u in standard GNU Emacs). The function 'insert-any-date' only outputs to one format, which is the same format as 'insert-todays-date' without a prefix. Imenu produces menus for accessing locations in documents, typically in the
current buffer. You can access the locations using an ordinary menu (menu bar or
other) or using minibuffer completion, or you can install 'imenu-list' and have
the imenu displayed as a vertical split that you can toggle show/hide.
| COMMAND | DESCRIPTION | KEYBINDING |
|-------------------------+----------------------------------+------------|
| counsel-imenu | /Menu to jump to places in buffer/ | SPC s i |
| imenu-list-smart-toggle | /Toggle imenu shown in a sidebar/ | SPC t i |
#+BEGIN_SRC emacs-lisp
(setq imenu-list-focus-after-activation t)
(map! :leader
(:prefix ("s" . "Search")
:desc "Menu to jump to places in buffer" "i" #'counsel-imenu))
(map! :leader
(:prefix ("t" . "Toggle")
:desc "Toggle imenu shown in a sidebar" "i" #'imenu-list-smart-toggle))
#+END_SRC
* Insert date
Some custom functions to insert the date. The function 'insert-todays-date' can
be used one of three different ways: (1) just the keybinding without the
universal argument prefix, (2) with one universal argument prefix, or (3) with
two universal argument prefixes. The universal argument prefix is 'SPC-u' in
Doom Emacs (C-u in standard GNU Emacs). The function 'insert-any-date' only
outputs to one format, which is the same format as 'insert-todays-date' without
a prefix.
| COMMAND | EXAMPLE OUTPUT | KEYBINDING | | COMMAND | EXAMPLE OUTPUT | KEYBINDING |
|-----------------------+---------------------------+-----------------------| |-----------------------+---------------------------+-----------------------|
@ -588,15 +511,18 @@ Some custom functions to insert the date. The function 'insert-todays-date' can
:desc "Insert todays date" "t" #'dt/insert-todays-date)) :desc "Insert todays date" "t" #'dt/insert-todays-date))
#+end_src #+end_src
* IVY * Ivy
Ivy is a generic completion mechanism for Emacs. Ivy is a generic completion mechanism for Emacs.
** IVY-POSFRAME ** Ivy-posframe
Ivy-posframe is an ivy extension, which lets ivy use posframe to show its candidate menu. Some of the settings below involve: Ivy-posframe is an ivy extension, which lets ivy use posframe to show its
+ ivy-posframe-display-functions-alist -- sets the display position for specific programs candidate menu. Some of the settings below involve:
+ ivy-posframe-height-alist -- sets the height of the list displayed for specific programs + ivy-posframe-display-functions-alist -- sets the display position for specific
programs
+ ivy-posframe-height-alist -- sets the height of the list displayed for
specific programs
Available functions (positions) for 'ivy-posframe-display-functions-alist' # Available functions (positions) for 'ivy-posframe-display-functions-alist'
+ ivy-posframe-display-at-frame-center + ivy-posframe-display-at-frame-center
+ ivy-posframe-display-at-window-center + ivy-posframe-display-at-window-center
+ ivy-posframe-display-at-frame-bottom-left + ivy-posframe-display-at-frame-bottom-left
@ -605,7 +531,10 @@ Available functions (positions) for 'ivy-posframe-display-functions-alist'
+ ivy-posframe-display-at-point + ivy-posframe-display-at-point
+ ivy-posframe-display-at-frame-top-center + ivy-posframe-display-at-frame-top-center
=NOTE:= If the setting for 'ivy-posframe-display' is set to 'nil' (false), anything that is set to 'ivy-display-function-fallback' will just default to their normal position in Doom Emacs (usually a bottom split). However, if this is set to 't' (true), then the fallback position will be centered in the window. =NOTE:= If the setting for 'ivy-posframe-display' is set to 'nil' (false),
anything that is set to 'ivy-display-function-fallback' will just default to
their normal position in Doom Emacs (usually a bottom split). However, if this
is set to 't' (true), then the fallback position will be centered in the window.
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp
(setq ivy-posframe-display-functions-alist (setq ivy-posframe-display-functions-alist
@ -627,8 +556,9 @@ Available functions (positions) for 'ivy-posframe-display-functions-alist'
(ivy-posframe-mode 1) ; 1 enables posframe-mode, 0 disables it. (ivy-posframe-mode 1) ; 1 enables posframe-mode, 0 disables it.
#+END_SRC #+END_SRC
** IVY KEYBINDINGS ** Ivy keybindings
By default, Doom Emacs does not use 'SPC v', so the format I use for these bindings is 'SPC v' plus 'key'. By default, Doom Emacs does not use 'SPC v', so the format I use for these
bindings is 'SPC v' plus 'key'.
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp
(map! :leader (map! :leader
@ -637,8 +567,12 @@ By default, Doom Emacs does not use 'SPC v', so the format I use for these bindi
:desc "Ivy switch view" "v s" #'ivy-switch-view)) :desc "Ivy switch view" "v s" #'ivy-switch-view))
#+END_SRC #+END_SRC
* LINE SETTINGS * Line settings
I set comment-line to 'SPC TAB TAB' which is a rather comfortable keybinding for me on my ZSA Moonlander keyboard. The standard Emacs keybinding for comment-line is 'C-x C-;'. The other keybindings are for commands that toggle on/off various line-related settings. Doom Emacs uses 'SPC t' for "toggle" commands, so I choose 'SPC t' plus 'key' for those bindings. I set comment-line to 'SPC TAB TAB' which is a rather comfortable keybinding for
me on my ZSA Moonlander keyboard. The standard Emacs keybinding for
comment-line is 'C-x C-;'. The other keybindings are for commands that toggle
on/off various line-related settings. Doom Emacs uses 'SPC t' for "toggle"
commands, so I choose 'SPC t' plus 'key' for those bindings.
| COMMAND | DESCRIPTION | KEYBINDING | | COMMAND | DESCRIPTION | KEYBINDING |
|--------------------------+-------------------------------------------+-------------| |--------------------------+-------------------------------------------+-------------|
@ -659,7 +593,7 @@ 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
* MARKDOWN * Markdown
#+begin_src emacs-lisp #+begin_src emacs-lisp
(custom-set-faces (custom-set-faces
@ -672,8 +606,12 @@ I set comment-line to 'SPC TAB TAB' which is a rather comfortable keybinding for
'(markdown-header-face-6 ((t (:inherit markdown-header-face :height 1.2))))) '(markdown-header-face-6 ((t (:inherit markdown-header-face :height 1.2)))))
#+end_src #+end_src
* MINIMAP * Minimap
A minimap sidebar displaying a smaller version of the current buffer on either the left or right side. It highlights the currently shown region and updates its position automatically. Be aware that this minimap program does not work in Org documents. This is not unusual though because I have tried several minimap programs and none of them can handle Org. A minimap sidebar displaying a smaller version of the current buffer on either
the left or right side. It highlights the currently shown region and updates its
position automatically. Be aware that this minimap program does not work in Org
documents. This is not unusual though because I have tried several minimap
programs and none of them can handle Org.
| COMMAND | DESCRIPTION | KEYBINDING | | COMMAND | DESCRIPTION | KEYBINDING |
|--------------+-------------------------------------------+------------| |--------------+-------------------------------------------+------------|
@ -686,8 +624,9 @@ A minimap sidebar displaying a smaller version of the current buffer on either t
:desc "Toggle minimap-mode" "m" #'minimap-mode)) :desc "Toggle minimap-mode" "m" #'minimap-mode))
#+end_src #+end_src
* MODELINE * Modeline
The modeline is the bottom status bar that appears in Emacs windows. For more information on what is available to configure in the Doom modeline, check out: The modeline is the bottom status bar that appears in Emacs windows. For more
information on what is available to configure in the Doom modeline, check out:
https://github.com/seagle0128/doom-modeline https://github.com/seagle0128/doom-modeline
#+begin_src emacs-lisp #+begin_src emacs-lisp
@ -698,15 +637,19 @@ https://github.com/seagle0128/doom-modeline
doom-modeline-persp-icon t) ;; adds folder icon next to persp name doom-modeline-persp-icon t) ;; adds folder icon next to persp name
#+end_src #+end_src
* MOUSE SUPPORT * Mouse support
Adding mouse support in the terminal version of Emacs. Adding mouse support in the terminal version of Emacs.
#+begin_src emacs-lisp #+begin_src emacs-lisp
(xterm-mouse-mode 1) (xterm-mouse-mode 1)
#+end_src #+end_src
* NEOTREE * Neotree
Neotree is a file tree viewer. When you open neotree, it jumps to the current file thanks to neo-smart-open. The neo-window-fixed-size setting makes the neotree width be adjustable. Doom Emacs had no keybindings set for neotree. Since Doom Emacs uses 'SPC t' for 'toggle' keybindings, I used 'SPC t n' for toggle-neotree. Neotree is a file tree viewer. When you open neotree, it jumps to the current
file thanks to neo-smart-open. The neo-window-fixed-size setting makes the
neotree width be adjustable. Doom Emacs had no keybindings set for neotree.
Since Doom Emacs uses 'SPC t' for 'toggle' keybindings, I used 'SPC t n' for
toggle-neotree.
| COMMAND | DESCRIPTION | KEYBINDING | | COMMAND | DESCRIPTION | KEYBINDING |
|----------------+---------------------------+------------| |----------------+---------------------------+------------|
@ -724,8 +667,12 @@ Neotree is a file tree viewer. When you open neotree, it jumps to the current f
:desc "Open directory in neotree" "d n" #'neotree-dir) :desc "Open directory in neotree" "d n" #'neotree-dir)
#+END_SRC #+END_SRC
* OPEN SPECIFIC FILES * Open specific files
Keybindings to open files that I work with all the time using the find-file command, which is the interactive file search that opens with 'C-x C-f' in GNU Emacs or 'SPC f f' in Doom Emacs. These keybindings use find-file non-interactively since we specify exactly what file to open. The format I use for these bindings is 'SPC =' plus 'key' since Doom Emacs does not use 'SPC ='. Keybindings to open files that I work with all the time using the find-file
command, which is the interactive file search that opens with 'C-x C-f' in GNU
Emacs or 'SPC f f' in Doom Emacs. These keybindings use find-file
non-interactively since we specify exactly what file to open. The format I use
for these bindings is 'SPC =' plus 'key' since Doom Emacs does not use 'SPC ='.
| PATH TO FILE | DESCRIPTION | KEYBINDING | | PATH TO FILE | DESCRIPTION | KEYBINDING |
|--------------------------------+-----------------------+------------| |--------------------------------+-----------------------+------------|
@ -749,10 +696,15 @@ Keybindings to open files that I work with all the time using the find-file comm
:desc "Edit eshell profile" "p" #'(lambda () (interactive) (find-file "~/.config/doom/eshell/profile")))) :desc "Edit eshell profile" "p" #'(lambda () (interactive) (find-file "~/.config/doom/eshell/profile"))))
#+END_SRC #+END_SRC
* ORG MODE * Org mode
I wrapped most of this block 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, org-superstar and org-roam by adding (+journal +pretty +roam2) to the org section of my Doom Emacs init.el. I wrapped most of this block 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, org-superstar and org-roam by
adding (+journal +pretty +roam2) to the org section of my Doom Emacs init.el.
=NOTE:= I have the location of my Org directory and Roam directory in $HOME/nc/ which is a Nextcloud folder that allows me to instantly sync all of my Org work between my home computer and my office computer. =NOTE:= I have the location of my Org directory and Roam directory in $HOME/nc/
which is a Nextcloud folder that allows me to instantly sync all of my Org work
between my home computer and my office computer.
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp
(map! :leader (map! :leader
@ -787,7 +739,10 @@ I wrapped most of this block in (after! org). Without this, my settings might b
#+END_SRC #+END_SRC
** Org fonts ** Org fonts
I have created an interactive function for each color scheme (M-x dt/org-colors-*). These functions will set appropriate colors and font attributes for org-level fonts and the org-table font. I have created an interactive function for each color scheme (M-x
dt/org-colors-*). These functions will set appropriate colors and font
attributes for org-level fonts and the org-table font.
#+begin_src emacs-lisp #+begin_src emacs-lisp
(defun dt/org-colors-doom-one () (defun dt/org-colors-doom-one ()
@ -956,8 +911,11 @@ I have created an interactive function for each color scheme (M-x dt/org-colors-
#+end_src #+end_src
** Org-export ** Org-export
We need ox-man for "Org eXporting" to manpage format and ox-gemini for exporting to gemtext (for the gemini protocol). We need ox-man for "Org eXporting" to manpage format and ox-gemini for exporting
=NOTE:= I also enable ox-publish for converting an Org site into an HTML site, but that is done in init.el (org +publish). to gemtext (for the gemini protocol).
=NOTE:= I also enable ox-publish for converting an Org site into an HTML site,
but that is done in init.el (org +publish).
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp
(use-package ox-man) (use-package ox-man)
@ -991,15 +949,15 @@ We need ox-man for "Org eXporting" to manpage format and ox-gemini for exporting
#+end_src #+end_src
* PASSWORD STORE * Perspective
Uses the standard Unix password store "pass". Perspective provides multiple named workspaces (or "perspectives") in Emacs,
similar to having multiple desktops in window managers like Awesome and XMonad.
#+begin_src emacs-lisp Each perspective has its own buffer list and its own window layout, making it
(use-package! password-store) easy to work on many separate projects without getting lost in all the buffers.
#+end_src Switching to a perspective activates its window configuration, and when in a
perspective, only its buffers are available (by default). Doom Emacs uses 'SPC
* PERSPECTIVE some_key' for binding some of the perspective commands, so I used this binging
Perspective provides multiple named workspaces (or "perspectives") in Emacs, similar to having multiple desktops in window managers like Awesome and XMonad. Each perspective has its own buffer list and its own window layout, making it easy to work on many separate projects without getting lost in all the buffers. Switching to a perspective activates its window configuration, and when in a perspective, only its buffers are available (by default). Doom Emacs uses 'SPC some_key' for binding some of the perspective commands, so I used this binging format for the perspective bindings that I created.. format for the perspective bindings that I created..
| COMMAND | DESCRIPTION | KEYBINDING | | COMMAND | DESCRIPTION | KEYBINDING |
|----------------------------+-------------------------------------+------------| |----------------------------+-------------------------------------+------------|
@ -1021,8 +979,11 @@ Perspective provides multiple named workspaces (or "perspectives") in Emacs, sim
:desc "Remove perspective by name" "-" #'persp-remove-by-name) :desc "Remove perspective by name" "-" #'persp-remove-by-name)
#+end_src #+end_src
* RAINBOW MODE * Rainbow mode
Rainbox mode displays the actual color for any hex value color. It's such a nice feature that I wanted it turned on all the time, regardless of what mode I am in. The following creates a global minor mode for rainbow-mode and enables it. Rainbox mode displays the actual color for any hex value color. It's such a
nice feature that I wanted it turned on all the time, regardless of what mode I
am in. The following creates a global minor mode for rainbow-mode and enables
it.
#+begin_src emacs-lisp #+begin_src emacs-lisp
(define-globalized-minor-mode global-rainbow-mode rainbow-mode (define-globalized-minor-mode global-rainbow-mode rainbow-mode
@ -1030,8 +991,15 @@ Rainbox mode displays the actual color for any hex value color. It's such a nic
(global-rainbow-mode 1 ) (global-rainbow-mode 1 )
#+end_src #+end_src
* REGISTERS * Registers
Emacs registers are compartments where you can save text, rectangles and positions for later use. Once you save text or a rectangle in a register, you can copy it into the buffer once or many times; once you save a position in a register, you can jump back to that position once or many times. The default GNU Emacs keybindings for these commands (with the exception of counsel-register) involves 'C-x r' followed by one or more other keys. I wanted to make this a little more user friendly, and since I am using Doom Emacs, I choose to replace the 'C-x r' part of the key chords with 'SPC r'. Emacs registers are compartments where you can save text, rectangles and
positions for later use. Once you save text or a rectangle in a register, you
can copy it into the buffer once or many times; once you save a position in a
register, you can jump back to that position once or many times. The default
GNU Emacs keybindings for these commands (with the exception of
counsel-register) involves 'C-x r' followed by one or more other keys. I wanted
to make this a little more user friendly, and since I am using Doom Emacs, I
choose to replace the 'C-x r' part of the key chords with 'SPC r'.
| COMMAND | DESCRIPTION | KEYBINDING | | COMMAND | DESCRIPTION | KEYBINDING |
|----------------------------------+----------------------------------+------------| |----------------------------------+----------------------------------+------------|
@ -1063,13 +1031,14 @@ 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
* 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.
+ 'eshell-aliases-file' -- sets an aliases file for the eshell. + 'eshell-aliases-file' -- sets an aliases file for the eshell.
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp
(setq shell-file-name "/bin/fish" (setq shell-file-name "/bin/bash"
vterm-max-scrollback 5000) vterm-max-scrollback 5000)
(setq eshell-rc-script "~/.config/doom/eshell/profile" (setq eshell-rc-script "~/.config/doom/eshell/profile"
eshell-aliases-file "~/.config/doom/eshell/aliases" eshell-aliases-file "~/.config/doom/eshell/aliases"
@ -1086,8 +1055,14 @@ Settings for the various shells and terminal emulators within Emacs.
:desc "Vterm popup toggle" "v t" #'+vterm/toggle) :desc "Vterm popup toggle" "v t" #'+vterm/toggle)
#+END_SRC #+END_SRC
* SPLITS * Splits
I set splits to default to opening on the right using 'prefer-horizontal-split'. I set a keybinding for 'clone-indirect-buffer-other-window' for when I want to have the same document in two splits. The text of the indirect buffer is always identical to the text of its base buffer; changes made by editing either one are visible immediately in the other. But in all other respects, the indirect buffer and its base buffer are completely separate. For example, I can fold one split but other will be unfolded. I set splits to default to opening on the right using 'prefer-horizontal-split'.
I set a keybinding for 'clone-indirect-buffer-other-window' for when I want to
have the same document in two splits. The text of the indirect buffer is always
identical to the text of its base buffer; changes made by editing either one are
visible immediately in the other. But in all other respects, the indirect
buffer and its base buffer are completely separate. For example, I can fold one
split but other will be unfolded.
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp
(defun prefer-horizontal-split () (defun prefer-horizontal-split ()
@ -1098,8 +1073,11 @@ I set splits to default to opening on the right using 'prefer-horizontal-split'.
:desc "Clone indirect buffer other window" "b c" #'clone-indirect-buffer-other-window) :desc "Clone indirect buffer other window" "b c" #'clone-indirect-buffer-other-window)
#+END_SRC #+END_SRC
* WINNER MODE * Winner mode
Winner mode has been included with GNU Emacs since version 20. This is a global minor mode and, when activated, it allows you to “undo” (and “redo”) changes in the window configuration with the key commands 'SCP w <left>' and 'SPC w <right>'. Winner mode has been included with GNU Emacs since version 20. This is a global
minor mode and, when activated, it allows you to “undo” (and “redo”) changes in
the window configuration with the key commands 'SCP w <left>' and 'SPC w
<right>'.
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp
(map! :leader (map! :leader
@ -1108,8 +1086,13 @@ Winner mode has been included with GNU Emacs since version 20. This is a global
:desc "Winner undo" "<left>" #'winner-undo)) :desc "Winner undo" "<left>" #'winner-undo))
#+END_SRC #+END_SRC
* ZAP TO CHAR * Zap to char
Emacs provides a 'zap-to-char' command that kills from the current point to a character. It is bound to 'M-z' in standard GNU Emacs but since Doom Emacs uses 'SPC' as its leader key and does not have 'SPC z' binded to anything, it just makes since to use it for 'zap-to-char'. Note that 'zap-to-char' can be used with the universal argument 'SPC u' to modify its behavior. Examples of 'zap-to-char' usage are listed in the table below: Emacs provides a 'zap-to-char' command that kills from the current point to a
character. It is bound to 'M-z' in standard GNU Emacs but since Doom Emacs uses
'SPC' as its leader key and does not have 'SPC z' binded to anything, it just
makes since to use it for 'zap-to-char'. Note that 'zap-to-char' can be used
with the universal argument 'SPC u' to modify its behavior. Examples of
'zap-to-char' usage are listed in the table below:
| KEYBINDING | WHAT IS DOES | | KEYBINDING | WHAT IS DOES |
|---------------------------+------------------------------------------------------------| |---------------------------+------------------------------------------------------------|
@ -1119,11 +1102,20 @@ Emacs provides a 'zap-to-char' command that kills from the current point to a ch
| SPC u -2 SPC z e | deletes all chars to the fourth previous occurrence of 'e' | | SPC u -2 SPC z e | deletes all chars to the fourth previous occurrence of 'e' |
| SPC u 1 0 0 SPC u SPC z e | deletes all chars to the 100th occurrence of 'e' | | SPC u 1 0 0 SPC u SPC z e | deletes all chars to the 100th occurrence of 'e' |
=TIP:= The universal argument (SPC u) can only take a single integer by default. If you need to use a multi-digit number (like 100 in the last example in the table above), then you must terminate the universal argument with another 'SPC u' after typing the number. =TIP:= The universal argument (SPC u) can only take a single integer by default.
If you need to use a multi-digit number (like 100 in the last example in the
table above), then you must terminate the universal argument with another 'SPC
u' after typing the number.
'zap-up-to-char' is an alternative command that does not zap the char specified. It is binded to 'SPC Z'. It can also be used in conjunction with the universal argument 'SPC u' in similar fashion to the the 'zap-to-char' examples above. 'zap-up-to-char' is an alternative command that does not zap the char specified.
It is binded to 'SPC Z'. It can also be used in conjunction with the universal
argument 'SPC u' in similar fashion to the the 'zap-to-char' examples above.
=NOTE:= Vim (evil mode) has similar functionality builtin. You can delete to the next occurrence of 'e' by using 'dte' in normal. To delete to the next occurrence of 'e' including the 'e', then you would use 'dfe'. And you can modify 'dt' and 'df' by prefixing them with numbers, so '2dte' would delete to the second occurrence of 'e'. =NOTE:= Vim (evil mode) has similar functionality builtin. You can delete to
the next occurrence of 'e' by using 'dte' in normal. To delete to the next
occurrence of 'e' including the 'e', then you would use 'dfe'. And you can
modify 'dt' and 'df' by prefixing them with numbers, so '2dte' would delete to
the second occurrence of 'e'.
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp
(map! :leader (map! :leader
@ -1131,13 +1123,8 @@ Emacs provides a 'zap-to-char' command that kills from the current point to a ch
:desc "Zap up to char" "Z" #'zap-up-to-char) :desc "Zap up to char" "Z" #'zap-up-to-char)
#+END_SRC #+END_SRC
* MASTODON * Transparency
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp
(setq mastodon-instance-url "https://fosstodon.org" (set-frame-parameter (selected-frame) 'alpha '(98 . 80))
mastodon-active-user "d4r1us-drk") (add-to-list 'default-frame-alist '(alpha . (98 . 80)))
#+END_SRC
* TRANSPARENCY
#+BEGIN_SRC emacs-lisp
(set-frame-parameter (selected-frame) 'alpha '(95 . 80))
(add-to-list 'default-frame-alist '(alpha . (95 . 80)))
#+END_SRC #+END_SRC

View file

@ -1,4 +1,3 @@
================= =============== =============== ======== ======== ================= =============== =============== ======== ========
\\ . . . . . . .\\ //. . . . . . .\\ //. . . . . . .\\ \\. . .\\// . . // \\ . . . . . . .\\ //. . . . . . .\\ //. . . . . . .\\ \\. . .\\// . . //
||. . ._____. . .|| ||. . ._____. . .|| ||. . ._____. . .|| || . . .\/ . . .|| ||. . ._____. . .|| ||. . ._____. . .|| ||. . ._____. . .|| || . . .\/ . . .||

View file

@ -42,7 +42,7 @@
neotree ; a project drawer, like NERDTree for vim neotree ; a project drawer, like NERDTree for vim
ophints ; highlight the region an operation acts on ophints ; highlight the region an operation acts on
(popup +defaults) ; tame sudden yet inevitable temporary windows (popup +defaults) ; tame sudden yet inevitable temporary windows
tabs ; a tab bar for Emacs ;;tabs ; a tab bar for Emacs
;;treemacs ; a project drawer, like neotree but cooler ;;treemacs ; a project drawer, like neotree but cooler
;;unicode ; extended unicode support for various languages ;;unicode ; extended unicode support for various languages
vc-gutter ; vcs diff in the fringe vc-gutter ; vcs diff in the fringe
@ -75,7 +75,7 @@
:term :term
eshell ; the elisp shell that works everywhere eshell ; the elisp shell that works everywhere
shell ; simple shell REPL for Emacs shell ; simple shell REPL for Emacs
term ; basic terminal emulator for Emacs ;;term ; basic terminal emulator for Emacs
vterm ; the best terminal emulation in Emacs vterm ; the best terminal emulation in Emacs
:checkers :checkers
@ -128,12 +128,12 @@
;;fsharp ; ML stands for Microsoft's Language ;;fsharp ; ML stands for Microsoft's Language
;;fstar ; (dependent) types and (monadic) effects and Z3 ;;fstar ; (dependent) types and (monadic) effects and Z3
;;gdscript ; the language you waited for ;;gdscript ; the language you waited for
(go +lsp) ; the hipster dialect ;;(go +lsp) ; the hipster dialect
(haskell +dante) ; a language that's lazier than I am ;;(haskell +dante) ; a language that's lazier than I am
;;hy ; readability of scheme w/ speed of python ;;hy ; readability of scheme w/ speed of python
;;idris ; a language you can depend on ;;idris ; a language you can depend on
json ; At least it ain't XML json ; At least it ain't XML
(java +meghanada) ; the poster child for carpal tunnel syndrome ;;(java +meghanada) ; the poster child for carpal tunnel syndrome
javascript ; all(hope(abandon(ye(who(enter(here)))))) javascript ; all(hope(abandon(ye(who(enter(here))))))
;;julia ; a better, faster MATLAB ;;julia ; a better, faster MATLAB
;;kotlin ; a better, slicker Java(Script) ;;kotlin ; a better, slicker Java(Script)
@ -161,7 +161,7 @@
;;rest ; Emacs as a REST client ;;rest ; Emacs as a REST client
;;rst ; ReST in peace ;;rst ; ReST in peace
;;(ruby +rails) ; 1.step {|i| p "Ruby is #{i.even? ? 'love' : 'life'}"} ;;(ruby +rails) ; 1.step {|i| p "Ruby is #{i.even? ? 'love' : 'life'}"}
rust ; Fe2O3.unwrap().unwrap().unwrap().unwrap() ;;rust ; Fe2O3.unwrap().unwrap().unwrap().unwrap()
;;scala ; java, but good ;;scala ; java, but good
scheme ; a fully conniving family of lisps scheme ; a fully conniving family of lisps
sh ; she sells {ba,z,fi}sh shells on the C xor sh ; she sells {ba,z,fi}sh shells on the C xor
@ -180,10 +180,10 @@
:app :app
;;calendar ;;calendar
emms ;; emms
;;everywhere ; *leave* Emacs!? You must be joking ;;everywhere ; *leave* Emacs!? You must be joking
;;irc ; how neckbeards socialize ;;irc ; how neckbeards socialize
rss ; emacs as an RSS reader ;;rss ; emacs as an RSS reader
;;twitter ; twitter client https://twitter.com/vnought ;;twitter ; twitter client https://twitter.com/vnought
:config :config

View file

@ -63,11 +63,11 @@
(package! dired-open) (package! dired-open)
(package! dired-subtree) (package! dired-subtree)
(package! dmenu) (package! dmenu)
(package! elfeed-goodies)
(package! elpher) (package! elpher)
(package! emojify) (package! emojify)
(package! esxml) (package! esxml)
(package! evil-tutor) (package! evil-tutor)
(package! imenu-list)
(package! ivy-posframe) (package! ivy-posframe)
(package! mw-thesaurus) (package! mw-thesaurus)
(package! org-board) (package! org-board)
@ -76,7 +76,6 @@
(package! ox-gemini) (package! ox-gemini)
(package! pacmacs) (package! pacmacs)
(package! peep-dired) (package! peep-dired)
(package! password-store)
(package! rainbow-mode) (package! rainbow-mode)
(package! request) (package! request)
(package! resize-window) (package! resize-window)
@ -84,7 +83,8 @@
(package! tldr) (package! tldr)
(package! wc-mode) (package! wc-mode)
(package! beacon) (package! beacon)
(package! clippy)
(package! minimap) (package! minimap)
(package! olivetti) (package! olivetti)
(package! mastodon) (package! sharper)
(package! csproj-mode)
(package! dap-mode)