diff --git a/early-init.el b/early-init.el index 3992995..8523c89 100644 --- a/early-init.el +++ b/early-init.el @@ -51,9 +51,9 @@ (elpaca elpaca-use-package (elpaca-use-package-mode)) -;; tangling to generate scripts for the local bin directory. This +;; tangling to generate scripts for the local bin directory. This ;; causes the name of the scripts to be returned in the car of the -;; tangle command which is used to load the file. The net result is +;; tangle command which is used to load the file. The net result is ;; that not the initialization is loaded, but the first exported ;; script. (use-package ob-tangle) diff --git a/init.org b/init.org index fc863e4..dc603fd 100644 --- a/init.org +++ b/init.org @@ -12,7 +12,7 @@ - Refactor existing configuration ** Notes on Elpaca and dev versions of emacs. Elpaca needs the build date of emacs to compare to package versions or -something. However it does not support all dev versions. +something. However it does not support all dev versions. For guix emacs-next packages you can find the date with: ( in the source block below: @@ -96,15 +96,15 @@ one to use. #+END_SRC -Tangle the init file if it has been updated. I maintain the same +Tangle the init file if it has been updated. I maintain the same configuration on multiple machines and fetch changes with a ~git pull~ -outside emacs so there is on opportunity to tangle the new file. If +outside emacs so there is on opportunity to tangle the new file. If I see it is outdated I tangle it. #+BEGIN_SRC emacs-lisp :tangle "early-init.el" -;; tangling to generate scripts for the local bin directory. This +;; tangling to generate scripts for the local bin directory. This ;; causes the name of the scripts to be returned in the car of the -;; tangle command which is used to load the file. The net result is +;; tangle command which is used to load the file. The net result is ;; that not the initialization is loaded, but the first exported ;; script. (use-package ob-tangle) @@ -141,7 +141,7 @@ Also immediately set lexical binding mode. ** Set the garbage collector threshold, to avoid collections The emacs history goes back to times where memory was counted in -bytes, not gigabytes. We can afford to be a bit more generous with the +bytes, not gigabytes. We can afford to be a bit more generous with the garbage collector settings. #+begin_src emacs-lisp @@ -175,7 +175,7 @@ on the time since start. *** Save customizations in a separate file By default customization settings are saved at the end of the *init.el* -file. This wreaks havoc with managing the files in git and will not +file. This wreaks havoc with managing the files in git and will not work with the tangled version anyway as it will be removed/overwritten each time the file is regenerated. Here we set the location of the file to save the customizations and @@ -189,38 +189,26 @@ then load it. (load custom-file nil :nomessage)) #+END_SRC -*** Load the General - -Needs to load early so the ~:general~ keyword is available for ~use-package~. - -#+BEGIN_SRC emacs-lisp - (use-package general :ensure t :demand t) - - -#+END_SRC - -#+RESULTS: - *** Enable Undo Tree -undo-tree is my preferred way of undoing and redoing stuff. The main reason is it doesn’t create a linear undo/redo history, but rather a complete tree you can navigate to see your complete editing history. One of the two obvious things to do are to tell Emacs to save all its undo history fies in a dedicated directory, otherwise we’d risk littering all of our directories. The second thing is to simply globally enable its mode. +undo-tree is my preferred way of undoing and redoing stuff. The main reason is it doesn’t create a linear undo/redo history, but rather a complete tree you can navigate to see your complete editing history. One of the two obvious things to do are to tell Emacs to save all its undo history fies in a dedicated directory, otherwise we’d risk littering all of our directories. The second thing is to simply globally enable its mode. #+BEGIN_SRC emacs-lisp -(use-package undo-tree - :defer t - :straight (:build t) - :custom - (undo-tree-history-directory-alist - `(("." . ,(expand-file-name (file-name-as-directory "undo-tree-hist") - user-emacs-directory)))) - :init - (global-undo-tree-mode) - :config - (setq undo-tree-visualizer-diff t - undo-tree-auto-save-history t - undo-tree-enable-undo-in-region t - undo-limit (* 800 1024) - undo-strong-limit (* 12 1024 1024) - undo-outer-limit (* 128 1024 1024))) + (use-package undo-tree + :defer t + :ensure t + :custom + (undo-tree-history-directory-alist + `(("." . ,(expand-file-name (file-name-as-directory "undo-tree-hist") + user-emacs-directory)))) + :init + (global-undo-tree-mode) + :config + (setq undo-tree-visualizer-diff t + undo-tree-auto-save-history t + undo-tree-enable-undo-in-region t + undo-limit (* 800 1024) + undo-strong-limit (* 12 1024 1024) + undo-outer-limit (* 128 1024 1024))) #+END_SRC @@ -258,9 +246,9 @@ undo-tree is my preferred way of undoing and redoing stuff. The main reason is i ** Get latest version of a github released project -Many projects nowadays use github to release their software. However +Many projects nowadays use github to release their software. However there is no easy way to get the latest version of a project -provided. This functions uses the releases API to get the latest +provided. This functions uses the releases API to get the latest metadata and get the version number from the JSON. #+BEGIN_SRC emacs-lisp @@ -311,30 +299,30 @@ Here’s a breakdown of what each line does: 1. *(set-default-coding-systems 'utf-8)* - This line sets the default coding system for new buffers. When you + This line sets the default coding system for new buffers. When you create a new buffer or open a file, Emacs will use UTF-8 encoding - by default. It will also set the default terminal and keyboard - coding systems. This applies to all internal operations where a + by default. It will also set the default terminal and keyboard + coding systems. This applies to all internal operations where a specific coding system has not been specified. 2. *(set-language-environment 'utf-8)* - This sets the language environment to UTF-8. Emacs uses the + This sets the language environment to UTF-8. Emacs uses the language environment to guess the preferred coding systems for - reading and writing files and for other operations. Setting this to + reading and writing files and for other operations. Setting this to UTF-8 ensures that UTF-8 is preferred in all language-related contexts. 3. *(setq locale-coding-system 'utf-8)* This sets the coding system for locale data, such as environment - variables and system messages. It ensures that Emacs correctly + variables and system messages. It ensures that Emacs correctly interprets UTF-8 encoded data coming from the operating system. 4. *(prefer-coding-system 'utf-8)* This makes UTF-8 the preferred coding system for any situation - where Emacs needs to choose an encoding. It ensures that Emacs + where Emacs needs to choose an encoding. It ensures that Emacs prefers UTF-8 over other encodings. 5. *(setq x-select-request-type ...)* @@ -378,7 +366,7 @@ command line and, of course, in *Emacs*. #+END_SRC This enables *pass* secrets to be used for all subsystems supporting -*auth-source* (which are probably all of them nowadays). It does require +*auth-source* (which are probably all of them nowadays). It does require some finagling to map the parts on the name in the pass system. - [[https://www.passwordstore.org/][Pass Website]] @@ -387,7 +375,7 @@ some finagling to map the parts on the name in the pass system. *** Use of Pass Secrets in ELisp It is very convenient to get secrets from this store (once gpg is set -up, which a totally different can of worms). A function +up, which a totally different can of worms). A function `auth-source-pass-get` is provided : #+BEGIN_SRC emacs-lisp :tangle no @@ -400,7 +388,7 @@ up, which a totally different can of worms). A function ** GUIX support [[https://gitlab.com/emacs-guix/emacs-guix][Emacs-guix]] is a module to interact with the guix system and help -manage packages and profiles. It also offers support for creating +manage packages and profiles. It also offers support for creating additional profiles and packages for Guix. #+BEGIN_SRC emacs-lisp @@ -451,19 +439,6 @@ It provides a minor-mode : [nil 26383 36877 803383 nil elpaca-process-queues nil nil 768000 nil] -** Collect visible URLs to open in browser - -#+BEGIN_SRC emacs-lisp - (use-package fancy-ffap-menu - :ensure (:host "codeberg.org" :repo "kakafarm/emacs-fancy-ffap-menu" - :main "fancy-ffap-menu.el") - :commands (fancy-ffap-menu-list-urls) - ) -#+END_SRC - -#+RESULTS: -: [nil 26432 21940 582674 nil elpaca-process-queues nil nil 547000 nil] - * Editor Features #+BEGIN_SRC emacs-lisp @@ -481,7 +456,7 @@ It provides a minor-mode ;; Support opening new minibuffers from inside existing minibuffers. (enable-recursive-minibuffers t) ;; Hide commands in M-x which do not work in the current mode. Vertico - ;; commands are hidden in normal buffers. This setting is useful beyond + ;; commands are hidden in normal buffers. This setting is useful beyond ;; Vertico. (read-extended-command-predicate #'command-completion-default-include-p) :init @@ -505,12 +480,12 @@ It provides a minor-mode ** Enable undo-tree -see [[https://elpa.gnu.org/packages/undo-tree.html][undo-tree web page]]. There is a lot of background info there to +see [[https://elpa.gnu.org/packages/undo-tree.html][undo-tree web page]]. There is a lot of background info there to explain the problems and solutions. Emacs actually maintains undo/redo information is an way that any -state can be restored. Both undo and redo is remembered in contrast to -many apps which essentially reset after doing a redo operation. It is +state can be restored. Both undo and redo is remembered in contrast to +many apps which essentially reset after doing a redo operation. It is very hard to keep track of the state using the normal undo/redo machinery to restore a specific state by tracking the branching naturranching nature. @@ -551,7 +526,7 @@ In the visualizer you can navigate the undo/redo state with: ** Save history over sessions -Persist history over Emacs restarts. Vertico sorts by history +Persist history over Emacs restarts. Vertico sorts by history position. #+BEGIN_SRC emacs-lisp @@ -564,7 +539,7 @@ position. ** Completion Configuration *** Use Vertico for better selection lists -Vertico is a big package by minad. Well documented in the [[https://github.com/minad/vertico][vertico +Vertico is a big package by minad. Well documented in the [[https://github.com/minad/vertico][vertico github repo]]. #+BEGIN_SRC emacs-lisp @@ -624,7 +599,7 @@ See the excellent documentation on [[https://github.com/minad/consult][Minad's c ;; Example configuration for Consult (use-package consult :ensure t - ;; Replace bindings. Lazily loaded by `use-package'. + ;; Replace bindings. Lazily loaded by `use-package'. :bind (;; C-c bindings in `mode-specific-map' ("C-c M-x" . consult-mode-command) ("C-c h" . consult-history) @@ -678,14 +653,14 @@ See the excellent documentation on [[https://github.com/minad/consult][Minad's c ("M-s" . consult-history) ;; orig. next-matching-history-element ("M-r" . consult-history)) ;; orig. previous-matching-history-element - ;; Enable automatic preview at point in the *Completions* buffer. This is + ;; Enable automatic preview at point in the *Completions* buffer. This is ;; relevant when you use the default completion UI. :hook (completion-list-mode . consult-preview-at-point-mode) ;; The :init configuration is always executed (Not lazy) :init - ;; Optionally configure the register formatting. This improves the register + ;; Optionally configure the register formatting. This improves the register ;; preview for `consult-register', `consult-register-load', ;; `consult-register-store' and the Emacs built-ins. (setq register-preview-delay 0.5 @@ -703,7 +678,7 @@ See the excellent documentation on [[https://github.com/minad/consult][Minad's c ;; after lazily loading the package. :config - ;; Optionally configure preview. The default value + ;; Optionally configure preview. The default value ;; is 'any, such that any key triggers the preview. ;; (setq consult-preview-key 'any) ;; (setq consult-preview-key "M-.") @@ -733,84 +708,6 @@ See the excellent documentation on [[https://github.com/minad/consult][Minad's c : [nil 26434 3705 536018 nil elpaca-process-queues nil nil 266000 nil] -** Evil Vim Keybindings - -#+BEGIN_SRC emacs-lisp - ;; load evil - (use-package evil - :ensure t ;; install the evil package if not installed - :init ;; tweak evil's configuration before loading it - (setq evil-search-module 'evil-search) - (setq evil-ex-complete-emacs-commands nil) - (setq evil-vsplit-window-right t) - (setq evil-split-window-below t) - (setq evil-shift-round nil) - (setq evil-want-C-u-scroll nil) - :config - (evil-mode) - ;; set leader keys - (evil-set-leader nil (kbd "C-SPC")) - (evil-set-leader 'normal (kbd "SPC")) - (evil-set-leader 'normal "," t) ;; set localleader - - ;; make vc commands available via leader key - (evil-define-key 'normal 'global - (kbd "v") vc-prefix-map) - (keymap-global-set "C-c v" vc-prefix-map) - ;; make project commands available via leader key - (evil-define-key 'normal 'global - (kbd "p") project-prefix-map) - (keymap-global-set "C-c p" project-prefix-map) - - (evil-define-key 'normal 'global - (kbd "ff") #'find-file - (kbd "fo") #'recentf - (kbd "fr") #'revert-buffer - (kbd "fd") #'diff-buffer-with-file) - (keymap-global-set "C-c f f" #'find-file) - (keymap-global-set "C-c f o" #'recentf) - (keymap-global-set "C-c f r" #'revert-buffer) - (keymap-global-set "C-c f d" #'diff-buffer-with-file) - ) - -#+END_SRC - -** Load Evil Collection for comprehensive evil support - -#+BEGIN_SRC emacs-lisp - (use-package evil-collection - :ensure t - :after evil - :init - (evil-collection-init)) - -#+END_SRC - -** Harpoon configuration - -#+BEGIN_SRC emacs-lisp :tangle no - (use-package harpoon - :ensure t - :init - (setq pti-harpoon-map (make-sparse-keymap)) - (keymap-set pti-harpoon-map (kbd "h") 'harpoon-toggle-quick-menu) - (keymap-set pti-harpoon-map (kbd "a") 'harpoon-add-file) - (keymap-set pti-harpoon-map (kbd "f") 'harpoon-toggle-file) - (keymap-set pti-harpoon-map (kbd "j") 'harpoon-go-to-1) - (keymap-set pti-harpoon-map (kbd "k") 'harpoon-go-to-2) - (keymap-set pti-harpoon-map (kbd "l") 'harpoon-go-to-3) - (keymap-set pti-harpoon-map (kbd ";") 'harpoon-go-to-4) - (keymap-set pti-harpoon-map (kbd "h") 'harpoon-toggle-quick-menu) - :bind - (("h" . 'pti-harpoon-map) - ("C-c h" . 'pti-harpoon-map))) - -#+END_SRC - -#+RESULTS: -: [nil 26284 54919 318035 nil elpaca-process-queues nil nil 339000 nil] - - ** User Interface *** Display startup time #+BEGIN_SRC emacs-lisp @@ -882,7 +779,7 @@ See the excellent documentation on [[https://github.com/minad/consult][Minad's c *** Update configuration of each created frame -When running as daemon there is no graphical context. This means that +When running as daemon there is no graphical context. This means that all graphical related settings cannot be set properly at initial startup if we need to interrogate the capabilities of the current screen. @@ -998,9 +895,9 @@ Enables and configures Yasnippet, a template system for Emacs: #+END_SRC ** Enable LLM access with Ellama -Configures access to language models using Ellama. I don't know +Configures access to language models using Ellama. I don't know whether to put it under writing, comms or programming as it is equally -/useful(?)/ for either activity. So I promoted it to an Editor feature. +/useful(?)/ for either activity. So I promoted it to an Editor feature. #+BEGIN_SRC emacs-lisp (use-package llm @@ -1036,7 +933,7 @@ whether to put it under writing, comms or programming as it is equally #+RESULTS: : [nil 26420 49222 463525 nil elpaca-process-queues nil nil 237000 nil] -It seems the *gpt-4o* model provides better responses. I should +It seems the *gpt-4o* model provides better responses. I should investigate local models more. ** Dired Configuration @@ -1156,7 +1053,7 @@ This enables direnv globally. ** Enable breadcrumbs Show breadcrumbs in the header line to keep context of the file being -worked on. See the [[https://github.com/joaotavora/breadcrumb][breadcrumb repo]] for more details. +worked on. See the [[https://github.com/joaotavora/breadcrumb][breadcrumb repo]] for more details. #+BEGIN_SRC emacs-lisp (use-package breadcrumb @@ -1287,7 +1184,7 @@ testing in my [[file:~/org/snamellit/testfile.org::*User Journey Graph][org babe :defer 3) #+END_SRC - Mermaid needs support of the mermaid-cli which is a node package. It + Mermaid needs support of the mermaid-cli which is a node package. It can be installed with #+BEGIN_SRC shell :tangle no @@ -1306,9 +1203,9 @@ npm install -g @mermaid-js/mermaid-cli Requires nothing special, other than *plantuml.jar* archive installed. The following code block depends on [[*Get latest version of a github released project][Get latest version of a github -released project]] utility function. This block will check if there is a +released project]] utility function. This block will check if there is a plantuml.jar in the emacs config directory and if not download the -latest version from github. The `pti-download-latest-plantuml` is made +latest version from github. The `pti-download-latest-plantuml` is made interactive to manually install the latest version if needed. #+BEGIN_SRC emacs-lisp :lexical t @@ -1385,7 +1282,7 @@ interactive to manually install the latest version if needed. **** TODO Move babel test file to emacs config folder Alternatively I might add a sample after each configured block to keep -it in the same context. Hmmm.... sounds even better. +it in the same context. Hmmm.... sounds even better. *** Org Export @@ -1529,7 +1426,7 @@ gicrisf has [[https://github.com/gicrisf/ox-zola][created a package]] to export #+RESULTS: -It is a wrapper around ~ox-hugo~ to export org files to Zola. It +It is a wrapper around ~ox-hugo~ to export org files to Zola. It supports most features of it and directs the user to the [[https://ox-hugo.scripter.co/][the hugo exporter manual.]] @@ -1568,125 +1465,6 @@ exporter manual.]] #+RESULTS: : t -*** Evil Support for Org - -Better keybinding for evil mode from [[https://github.com/Somelauw/evil-org-mode][the evil-org github repo]]. -#+BEGIN_SRC emacs-lisp - (use-package evil-org - :ensure t - :after org - :hook - (org-mode . evil-org-mode) - :config - (require 'evil-org-agenda) - (evil-org-agenda-set-keys)) -#+END_SRC - -Here is a snapshot of the keybindings dd <2024-07-30 Tue>. - -**** Quick overview - - |----------------+---------------------------| - | key | explanation | - |----------------+---------------------------| - | gh, gj, gk, gl | navigate between elements | - | vae | select an element | - |----------------+---------------------------| - -**** Headings and items - - |--------------+------------------------| - | key | explanation | - |--------------+------------------------| - | M-ret | insert heading | - | , g TAB | fold / unfold headings | - | M-h or << | promote a heading | - | M-l or >> | demote a heading | - | M-k | move subtree up | - | M-j | move subtree down | - | M-S-h or aR | demote a subtree | - | vaR | select a subtree | - |--------------+------------------------| - -**** Tables - - |-----------+--------------------------------| - | key | explanation | - |-----------+--------------------------------| - | ( | previous table cell | - | ) | next table cell | - | { | beginning of table | - | } | end of table | - | M-h / M-l | move table column left / right | - | M-k / M-j | move table column up / down | - | vae | select table cell | - | vaE | select table row | - | var | select whole table | - |-----------+--------------------------------| - -**** Agenda - - |-------------------------+-------------------------+-----------------------------------------------------------------------------------| - | Evil key | Emacs key | explanation | - |-------------------------+-------------------------+-----------------------------------------------------------------------------------| - | gH | | Move cursor to the top of window | - | gM | | Move cursor to the middle of window | - | gL | | Move cursor to the bottom of window | - | , S- | | go to the corresponding entry at point | - | g TAB | | go to the corresponding entry at point | - | | | go to the Org mode file which contains the item at point | - | M- | L | Display Org file and center around the item | - | | | scroll up | - | or | or | scroll down | - | j, k | n, p | next, previous line | - | gj, gk, C-j, C-k | N, P | next, previous item | - | [, ] | b, f | previous, next week | - | J, K | -, +, S-down, S-up | down, up priority | - | H, L | S-left, S-right | modify date to earlier, later | - | t | t | cycle TODO keywords | - | M-j, M-k | M-down, M-up | drag line forward, backward | - | C-S-h, C-S-l | C-S-left, C-S-right | previous, next keyword | - | u | C-_, C-/ | undo | - | dd | C-k | delete item | - | da | a | ask and archive item | - | dA | $ | archive item | - | ct | : | set tags | - | ce | e | set effort | - | cT | ; | set timer | - | i | i | insert entry in diary | - | a | z | add note | - | A | A | append to agenda | - | C | k | capture | - | m | m | mark | - | * | * | toggle all marks | - | % | % | mark regexp | - | M | U | remove all marks | - | x | B | execute action on marks | - | gr | r | refresh agenda | - | gR | g | refresh all agendas | - | ZQ | x | exit agenda | - | ZZ | Q | quit agenda | - | gD | v | tweak display (deadlines, diary, follow/log-mode, entry text, grid, day/week/year | - | ZD | # | dim blocked tasks | - | sc, sr, se, st, s^ | <, =, _, /, ^ | filter by category, regexp, effort, tag, top headline | - | S | \vert | remove all filters | - | ss | ~ | filter/limit interactively | - | I | I | clock in | - | O | O | clock out | - | cg | J | jump to the currently clocked in task within the agenda | - | cc | X | cancel the current running clock | - | cr | R | toggle clocktable mode in an agenda buffer | - | . | . | go to today's date | - | gc | c | pop up calendar | - | gC | C | pop up date converter | - | p | > | pop up date selector | - | gh | H | pop up holiday calendar | - | gm | M | pop up phases of the moon | - | gs | S | pop up sunrise/sunset times | - | gt | T | pop up tag list | - | +, - | [, ] | manipulate the query by adding a search term with positive or negative selection | - |-------------------------+-------------------------+-----------------------------------------------------------------------------------| *** Org GCal Support @@ -1781,7 +1559,7 @@ projects: *** Daviwil's Productivity Tools -@daviwil has a set of productivity tools which are very useful. I have +@daviwil has a set of productivity tools which are very useful. I have **** Find all tasks with a specific tag (or without) @@ -1931,22 +1709,6 @@ We can add a list of queries ;; configure eglot-mode (use-package eglot :config - (evil-define-key 'normal eglot-mode-map - (kbd "c a") 'eglot-code-actions - (kbd "c d") 'eglot-find-declaration - (kbd "c i") 'eglot-find-implementation - (kbd "c k") 'eglot-find-typeDefinition - (kbd "c f") 'eglot-format - (kbd "c F") 'eglot-format-buffer - (kbd "c r") 'eglot-rename - (kbd "c Q") 'eglot-shutdown - (kbd "c q") 'eglot-reconnect - (kbd "c n") 'flymake-goto-next-error - (kbd "c p") 'flymake-goto-prev-error - (kbd "]d") #'flymake-goto-next-error - (kbd "[d") #'flymake-goto-prev-error - ) - ;; Shutdown server when last managed buffer is killed (setq eglot-autoshutdown t) @@ -1968,19 +1730,6 @@ We can add a list of queries #+END_SRC -*** Flymake Support - -#+BEGIN_SRC emacs-lisp - (defun pti-flymake-evil-keybindings () - "Map flymake error navigation to easier key sequences." - (evil-define-key 'normal flymake-mode-map - (kbd "]d") #'flymake-goto-next-error - (kbd "[d") #'flymake-goto-prev-error)) - - (add-hook 'flymake-mode-hook #'pti-flymake-evil-keybindings) -#+END_SRC - - *** Use Treesitter parser support #+BEGIN_SRC emacs-lisp @@ -2236,36 +1985,12 @@ see also [[https://www.masteringemacs.org/article/how-to-get-started-tree-sitter lisp-mode-hook scheme-mode-hook)) (add-hook mode #'enable-paredit-mode))) - (use-package evil-paredit - :ensure t - :commands (evil-paredit-mode) - :init - (dolist (mode '(emacs-lisp-mode-hook - lisp-interaction-mode-hook - lisp-mode-hook - scheme-mode-hook)) - (add-hook mode #'evil-paredit-mode))) + #+END_SRC #+RESULTS: -***** TODO FIx paredit bug related to obsolete macro -evil-paredit relies on an obsolete (and no longer available method) -`evil-called-interactively-p`. So I define it here till evil-paredit -has implemented the new method. - -#+BEGIN_SRC emacs-lisp -(defmacro evil-called-interactively-p () - "Wrapper for `called-interactively-p'. -In older versions of Emacs, `called-interactively-p' takes -no arguments. In Emacs 23.2 and newer, it takes one argument." - (called-interactively-p 'any)) -(make-obsolete 'evil-called-interactively-p - "please use (called-interactively-p 'any) instead." - "Git commit 222b791") - -#+END_SRC **** Rainbow Parentheses #+BEGIN_SRC emacs-lisp @@ -2404,7 +2129,7 @@ Configure Geiser and Scheme #+END_SRC #+RESULTS: -| evil-paredit-mode | geiser-mode | enable-paredit-mode | aggressive-indent-mode | geiser-mode--maybe-activate | +| | geiser-mode | enable-paredit-mode | aggressive-indent-mode | geiser-mode--maybe-activate | **** Enable Cider for Clojure mode @@ -2497,15 +2222,7 @@ This function has to be called in the *sly-inferior-lisp* :config (setq terraform-indent-level 2 - terraform-format-on-save t) - (evil-define-key 'normal terraform-mode-map - (kbd "c k") #'terraform-open-doc - (kbd "c f") #'terraform-format - (kbd "c F") #'terraform-format-buffer - (kbd "c n") 'flymake-goto-next-error - (kbd "c p") 'flymake-goto-prev-error - (kbd "]d") #'flymake-goto-next-error - (kbd "[d") #'flymake-goto-prev-error)) + terraform-format-on-save t)) #+END_SRC Map the keymap consistently to the eglot mappings. @@ -2571,8 +2288,7 @@ Map the keymap consistently to the eglot mappings. ;; (setq dape-repl-use-shorthand t) ;; By default dape uses gdb keybinding prefix - ;; (setq dape-key-prefix "d") - (evil-define-key 'normal 'global (kbd "d") dape-global-map) + (setq dape-key-prefix "d") ;; Kill compile buffer on build success ;; (add-hook 'dape-compile-compile-hooks 'kill-buffer) @@ -2659,8 +2375,7 @@ Map the keymap consistently to the eglot mappings. :branch "main" :files ("dist" "*.el")) :bind - (:map evil-insert-state-map - ("C-y" . copilot-accept-completion)) + ("C-y" . copilot-accept-completion) :config (add-to-list 'copilot-indentation-alist '(scheme-mode . 2)) (add-to-list 'copilot-indentation-alist '(emacs-lisp-mode . 2)) @@ -2732,7 +2447,7 @@ Setup all channels which are joined by default. *** ERC connect function -Define a function to login to ERC when needed. In principle ERC +Define a function to login to ERC when needed. In principle ERC reconnects after suspend, and sometimes it even works, but mostly I run this function again to reconnect, which will update the buffers with the rooms I joined. @@ -2757,10 +2472,10 @@ in all kind of weird situation. **** TODO Figure out how to make ERC reconnect more reliably Although running `snam-erc` is not a big deal, it should not be needed -so much. I should figure out in what cases reconnects fail or dropping +so much. I should figure out in what cases reconnects fail or dropping connections fail to be recognized. I often see that ERC is _reconnecting_ however this seems to silently -fail. I dunno, there is something fishy here... +fail. I dunno, there is something fishy here... *** Integrate ERC with i3 Desktops @@ -2874,9 +2589,9 @@ Configures Elfeed, an RSS feed reader for Emacs: #+RESULTS: : [nil 26289 17361 350243 nil elpaca-process-queues nil nil 817000 nil] -This does all kind of weird things. Apparently elpaca or use-package +This does all kind of weird things. Apparently elpaca or use-package magically namespaces all the functions and for some reason it fails -to require 'elfeed'. ... The weird thing is that the emacs lips +to require 'elfeed'. ... The weird thing is that the emacs lips feature is used to expand o2e to opml-to-elfeed-feeds, by setting the `read-symbol-shorthands` variable to `(("o2e" . "opml-to-elfeed-feeds"))`. @@ -2927,12 +2642,6 @@ Indicates the ~init.el~ file is provided by and ends here: (report-time-since-load "Future") #+END_SRC -** TODO Decide about general keybindings. -The *general* package offers enhanced support for *evil* keybindings, -notably it integrates with *use-package* to define keybindings which -will load the package if not loaded yet. -It considerably streamlines managing evil bindings so it should offer -enough value but I just removed it, so it'll have to wait a bit. ** NEXT Add support for zola blogposts writing in org-mode :LOGBOOK: CLOCK: [2024-08-15 Thu 13:47]--[2024-08-16 Fri 00:57] => 11:10