summaryrefslogtreecommitdiff
path: root/config.org
diff options
context:
space:
mode:
authorcashmere <cashmere@autistici.org>2025-10-10 13:14:26 +0200
committercashmere <cashmere@autistici.org>2025-10-10 13:14:26 +0200
commitbaa0a52c5f4bf22b44bb22071d57f73551db094d (patch)
tree2a5f9c12269aab2c31fbb477887b038f418b1ee9 /config.org
parente91479bd7e1dfa13245d76ca40e7a1c12132deb0 (diff)
downloademacs-baa0a52c5f4bf22b44bb22071d57f73551db094d.tar.gz
stabilize emacs and fix various errors
Diffstat (limited to 'config.org')
-rw-r--r--config.org484
1 files changed, 226 insertions, 258 deletions
diff --git a/config.org b/config.org
index c6200d5..8d3451c 100644
--- a/config.org
+++ b/config.org
@@ -7,16 +7,12 @@
;;; config.el --- Emacs-Kick --- A feature rich Emacs config for (neo)vi(m)mers -*- lexical-binding: t; -*-
;; (setenv "LSP_USE_PLISTS" "true")
-;; (setq gc-cons-threshold #x40000000)
+(setq gc-cons-threshold #x40000000)
-(setq read-process-output-max (* 1024 1024 4))
+;; (setq read-process-output-max (* 1024 1024 4))
;; (setq package-enable-at-startup nil)
-(when (boundp 'pgtk-wait-for-event-timeout)
- (setq pgtk-wait-for-event-timeout 0.001))
-(setq which-func-update-delay 1.0)
-(setq gnutls-algorithm-priority "NORMAL:-VERS-TLS1.3")
(set-language-environment "UTF-8")
(setq locale-coding-system 'utf-8)
(prefer-coding-system 'utf-8)
@@ -42,10 +38,11 @@
* Visual Optimizations
- Let's define some visual optimizations to change the appearnce of Emacs.
+Let's define some visual optimizations to change the appearnce of Emacs.
+
** Opacity
- To change the appearance of Emacs, lets start with the opacity. Setting it to 90% changes Emacs to a whole new level, as the colors of your theme and your background image harmonize with each other.
+To change the appearance of Emacs, lets start with the opacity. Setting it to 90% changes Emacs to a whole new level, as the colors of your theme and your background image harmonize with each otherd.
#+begin_src emacs-lisp
@@ -61,7 +58,6 @@
;;; EMACS
;; This is biggest one. Keep going, plugins (oops, I mean packages) will be shorter :)
-(setq debug-on-error nil)
(use-package emacs
:straight nil
:ensure nil
@@ -164,6 +160,7 @@
(emacs-init-time)
(length (hash-table-keys straight--recipe-cache))))))))
#+end_src
+
* emacs-kickstart font
#+begin_src emacs-lisp
@@ -172,6 +169,7 @@
:type 'boolean
:group 'appearance)
#+end_src
+
* window
#+begin_src emacs-lisp
@@ -220,6 +218,7 @@
(slot . 1))
)))
#+end_src
+
* dired
#+begin_src emacs-lisp
@@ -240,6 +239,7 @@
(when gls
(setq insert-directory-program gls)))))
#+end_src
+
* erc
#+begin_src emacs-lisp
@@ -252,6 +252,7 @@
(erc-timestamp-format "[%H:%M]") ;; Format for timestamps in messages.
(erc-autojoin-channels-alist '((".*\\.libera\\.chat" "#emacs"))));; Automatically join the #emacs channel on Libera.Chat.
#+end_src
+
* centered-cursor
[[https://entropicthoughts.com/centered-cursor-mode-in-vanilla-emacs][Centered Cursor Mode in Vanilla Emacs]]
@@ -277,6 +278,7 @@
(setq my/centered-cursor-enabled t)
(message "centered-cursor on"))))
#+end_src
+
* isearch
#+begin_src emacs-lisp
@@ -291,35 +293,36 @@
:bind (("C-s" . isearch-forward) ;; Bind C-s to forward isearch.
("C-r" . isearch-backward))) ;; Bind C-r to backward isearch.
#+end_src
+
* vc
#+begin_src emacs-lisp
(use-package vc
-:straight nil
- :ensure nil ;; This is built-in, no need to fetch it.
- :defer t
- :bind
- (("C-x v d" . vc-dir) ;; Open VC directory for version control status.
- ("C-x v =" . vc-diff) ;; Show differences for the current file.
- ("C-x v D" . vc-root-diff) ;; Show differences for the entire repository.
- ("C-x v v" . vc-next-action)) ;; Perform the next version control action.
- :config
- ;; Better colors for <leader> g b (blame file)
- (setq vc-annotate-color-map
-'((20 . "#f5e0dc")
- (40 . "#f2cdcd")
- (60 . "#f5c2e7")
- (80 . "#cba6f7")
- (100 . "#f38ba8")
- (120 . "#eba0ac")
- (140 . "#fab387")
- (160 . "#f9e2af")
- (180 . "#a6e3a1")
- (200 . "#94e2d5")
- (220 . "#89dceb")
- (240 . "#74c7ec")
- (260 . "#89b4fa")
- (280 . "#b4befe"))))
+ :straight nil
+ :ensure nil ;; This is built-in, no need to fetch it.
+ :defer t
+ :bind
+ (("C-x v d" . vc-dir) ;; Open VC directory for version control status.
+ ("C-x v =" . vc-diff) ;; Show differences for the current file.
+ ("C-x v D" . vc-root-diff) ;; Show differences for the entire repository.
+ ("C-x v v" . vc-next-action)) ;; Perform the next version control action.
+ :config
+ ;; Better colors for <leader> g b (blame file)
+ (setq vc-annotate-color-map
+ '((20 . "#f5e0dc")
+ (40 . "#f2cdcd")
+ (60 . "#f5c2e7")
+ (80 . "#cba6f7")
+ (100 . "#f38ba8")
+ (120 . "#eba0ac")
+ (140 . "#fab387")
+ (160 . "#f9e2af")
+ (180 . "#a6e3a1")
+ (200 . "#94e2d5")
+ (220 . "#89dceb")
+ (240 . "#74c7ec")
+ (260 . "#89b4fa")
+ (280 . "#b4befe"))))
#+end_src
* smerge
@@ -335,6 +338,7 @@
("C-c ^ n" . smerge-next) ;; Move to the next conflict.
("C-c ^ p" . smerge-previous))) ;; Move to the previous conflict.
#+end_src
+
* eldoc
#+begin_src emacs-lisp
@@ -351,6 +355,7 @@
:init
(global-eldoc-mode))
#+end_src
+
* flymake
Disabled because nix is managing the flymake configuration.
@@ -366,6 +371,7 @@ Disabled because nix is managing the flymake configuration.
'((error "!»" compilation-error) (warning "»" compilation-warning)
(note "»" compilation-info))))
#+end_src
+
* xref
#+begin_src emacs-lisp
@@ -373,6 +379,7 @@ Disabled because nix is managing the flymake configuration.
:straight nil
:ensure nil)
#+end_src
+
* project
#+begin_src emacs-lisp
@@ -380,15 +387,17 @@ Disabled because nix is managing the flymake configuration.
:straight nil
:ensure nil)
#+end_src
+
* org mode
- #+begin_src emacs-lisp
+#+begin_src emacs-lisp
(use-package org
- :straight nil
- :ensure nil
- :defer t
+ :straight nil
+ :ensure nil
+ :defer t
:config
(require 'org-tempo)
+
(custom-set-faces
'(org-document-title ((t (:height 1.6))))
'(outline-1 ((t (:height 1.25))))
@@ -400,11 +409,12 @@ Disabled because nix is managing the flymake configuration.
'(outline-7 ((t (:height 1.2))))
'(outline-8 ((t (:height 1.2))))
'(outline-9 ((t (:height 1.2)))))
-
+
(setq org-startup-folded 'nil)
- (setq org-adapt-indentation nil
+ (setq org-adapt-indentation t
org-hide-leading-stars t
org-pretty-entities t
+ org-startup-truncated t
org-ellipsis " ")
(setq org-src-fontify-natively t
org-src-tab-acts-natively t
@@ -415,17 +425,21 @@ Disabled because nix is managing the flymake configuration.
org-fold-catch-invisible-edits 'show-and-error
org-special-ctrl-a/e t
org-insert-heading-respect-content t)
-
+
(add-hook 'org-mode-hook 'variable-pitch-mode)
(add-hook 'org-mode-hook 'org-indent-mode)
+ (add-hook 'org-mode-hook 'visual-line-mode)
+ (add-hook 'org-mode-hook (lambda () (electric-indent-local-mode -1)))
+
+
(add-to-list 'font-lock-extra-managed-props 'display)
(font-lock-add-keywords 'org-mode
`(("^.*?\( \)\(:[[:alnum:]_@#%:]+:\)$"
(1 `(face nil
display (space :align-to (- right ,(org-string-width (match-string 2)) 3)))
prepend))) t))
+#+end_src
- #+end_src
** org-appear
#+begin_src emacs-lisp
@@ -438,6 +452,22 @@ Disabled because nix is managing the flymake configuration.
org-appear-autolinks t ;; Show links
org-appear-autosubmarkers t)) ;; Show sub- and superscripts
#+end_src
+
+** org-modern
+
+#+begin_src emacs-lisp
+ (use-package org-modern
+ :ensure t
+ :straight t
+ )
+ (with-eval-after-load 'org (global-org-modern-mode))
+
+ (setq org-modern-star 'fold)
+ (setq org-modern-fold-stars '(("◉" . "○")))
+ (setq org-modern-star 'replace)
+ (setq org-modern-replace-stars "◉○◉○◉")
+#+end_src
+
** org agenda
We will start of with setting some sane configuration for org agenda.
@@ -491,11 +521,8 @@ let us disable the predefined org agenda commands.
(org-deadline-warning-days 0))))))
#+end_src
-** org-babel
-
-#+begin_src emacs-lisp
-#+end_src
** exporter
+
*** typst
#+begin_src emacs-lisp
@@ -503,8 +530,10 @@ let us disable the predefined org agenda commands.
:straight (:host github :repo "jmpunkt/ox-typst")
:after org)
#+end_src
+
** denote
-Denote is objectively the best note taking extension, which you coul;d install. It has a very easy to parse file naming scheme and suports not only org files. It has also transclusion inclusive! if you are interested, then check it out yourself.
+
+Denote is objectively the best note taking extension, which you could install. It has a very easy to parse file naming scheme and suports not only org files. It has also transclusion inclusive! if you are interested, then check it out yourself.
#+begin_src emacs-lisp
(use-package denote
@@ -514,9 +543,10 @@ Denote is objectively the best note taking extension, which you coul;d install.
(setq denote-rename-buffer-mode 1
denote-directory (expand-file-name "~/org/")))
#+end_src
+
*** denote-agenda
-Denote itself focused on the last versions to have a core for note taking and to be independent of org. But of course you may extend it with your own extensions, functions and helper or even extensions by its developer. One of these extesions is =denote-agenda=, which allows you to dynamically add and remove org-agendas files based on a denote keyword. I set it to =task=, very simple. When we compare it with org-roam, It took me several days to achieve almost the same workflow, one or two external packages and around of 200 extra lines of code.
+Denote fitself focused on the last versions to have a core for note taking and to be independent of org. But of course you may extend it with your own extensions, functions and helper or even extensions by its developer. One of these extesions is =denote-agenda=, which allows you to dynamically add and remove org-agendas files based on a denote keyword. I set it to =task=, very simple. When we compare it with org-roam, It took me several days to achieve almost the same workflow, one or two external packages and around of 200 extra lines of code.
#+begin_src emacs-lisp
(use-package denote-agenda
@@ -557,15 +587,6 @@ Denote itself focused on the last versions to have a core for note taking and to
(which-key-idle-delay 0.3))
#+end_src
-* gcmh
- gcmh is for garbage collection
-
-#+begin_src emacs-lisp
-(use-package gcmh
- :config
- (gcmh-mode 1))
-#+end_src
-
* vertico
#+begin_src emacs-lisp
@@ -670,6 +691,8 @@ Denote itself focused on the last versions to have a core for note taking and to
:defer t
:custom
(corfu-auto t) ;; Only completes when hitting TAB
+ (corfu-cycle t)
+ (text-mode-ispell-word-completion nil)
(corfu-auto-delay 0.08) ;; Delay before popup (enable if corfu-auto is t)
(corfu-auto-prefix 1) ;; Trigger completion after typing 1 character
(corfu-quit-no-match t) ;; Quit popup if no match
@@ -784,6 +807,7 @@ completion-category-overrides '((file (styles partial-completion))))) ;; Customi
#+begin_src emacs-lisp
(use-package nix-mode
:ensure t
+ :defer t
:mode "\\.nix\\'")
#+end_src
@@ -795,6 +819,7 @@ completion-category-overrides '((file (styles partial-completion))))) ;; Customi
:mode "\\.typ\\'"
:hook (typst-ts-mode . eglot-ensure)
:config
+ :defer t
(with-eval-after-load 'eglot
(add-to-list 'eglot-server-programs
`(typst-ts-mode . ,(eglot-alternatives '("tinymist" "typst-lsp"))))))
@@ -812,38 +837,38 @@ completion-category-overrides '((file (styles partial-completion))))) ;; Customi
*** org babel integration
- #+begin_src emacs-lisp
- ;; Make sure rustic gets activated in the org-src block and add the original file's source code.
+#+begin_src emacs-lisp
+;; Make sure rustic gets activated in the org-src block and add the original file's source code.
(defun my-read-file-to-string (file)
- (with-temp-buffer
- (insert-file-contents file)
- (buffer-string)))
+(with-temp-buffer
+(insert-file-contents file)
+(buffer-string)))
(defun org-babel-edit-prep:rust (babel-info)
- (setq-local src-code (nth 1 babel-info))
- (setq-local buffer-file-name (expand-file-name (->> babel-info caddr (alist-get :tangle))))
- (setq-local buffer-src-code (replace-regexp-in-string src-code "" (my-read-file-to-string (buffer-file-name))))
- (goto-char (point-max))
- (insert buffer-src-code)
- (narrow-to-region (point-min) (+ (point-min) (length src-code)))
- (rustic-mode)
- (org-src-mode))
+(setq-local src-code (nth 1 babel-info))
+(setq-local buffer-file-name (expand-file-name (->> babel-info caddr (alist-get :tangle))))
+(setq-local buffer-src-code (replace-regexp-in-string src-code "" (my-read-file-to-string (buffer-file-name))))
+(goto-char (point-max))
+(insert buffer-src-code)
+(narrow-to-region (point-min) (+ (point-min) (length src-code)))
+(rustic-mode)
+(org-src-mode))
(defun my-delete-hidden-text ()
- (-let [p-start (point-max)]
- (widen)
- (delete-region p-start (point-max))))
+(-let [p-start (point-max)]
+(widen)
+(delete-region p-start (point-max))))
(define-advice org-edit-src-exit
- (:before (&rest _args) remove-src-block)
- (when (eq major-mode 'rustic-mode)
- (my-delete-hidden-text)))
+(:before (&rest _args) remove-src-block)
+(when (eq major-mode 'rustic-mode)
+(my-delete-hidden-text)))
(define-advice org-edit-src-save
- (:before (&rest _args) remove-src-block)
- (when (eq major-mode 'rustic-mode)
- (my-delete-hidden-text)))
- #+end_src
+(:before (&rest _args) remove-src-block)
+(when (eq major-mode 'rustic-mode)
+(my-delete-hidden-text)))
+#+end_src
* eglot
@@ -893,8 +918,9 @@ completion-category-overrides '((file (styles partial-completion))))) ;; Customi
* olivetti
#+begin_src emacs-lisp
- (use-package olivetti
- :defer t)
+(use-package olivetti
+ :ensure t
+ :defer t)
#+end_src
* eldoc
@@ -910,69 +936,48 @@ completion-category-overrides '((file (styles partial-completion))))) ;; Customi
#+begin_src emacs-lisp
- (use-package diff-hl
- :defer t
- :straight t
- :ensure t
- :hook
- (find-file . (lambda ()
- (global-diff-hl-mode) ;; Enable Diff-HL mode for all files.
- (diff-hl-flydiff-mode) ;; Automatically refresh diffs.
- (diff-hl-margin-mode))) ;; Show diff indicators in the margin.
- :custom
- (diff-hl-side 'left) ;; Set the side for diff indicators.
- (diff-hl-margin-symbols-alist '((insert . "┃") ;; Customize symbols for each change type.
- (delete . "-")
- (change . "┃")
- (unknown . "┆")
- (ignored . "i"))))
+(use-package diff-hl
+ :defer t
+ :straight t
+ :ensure t
+ :hook
+ (find-file . (lambda ()
+ (global-diff-hl-mode) ;; Enable Diff-HL mode for all files.
+ (diff-hl-flydiff-mode) ;; Automatically refresh diffs.
+ (diff-hl-margin-mode))) ;; Show diff indicators in the margin.
+ :custom
+ (diff-hl-side 'left) ;; Set the side for diff indicators.
+ (diff-hl-margin-symbols-alist '((insert . "┃") ;; Customize symbols for each change type.
+ (delete . "-")
+ (change . "┃")
+ (unknown . "┆")
+ (ignored . "i"))))
#+end_src
-* ff
+* magit
#+begin_src emacs-lisp
- (use-package magit
- :ensure t
- :straight t
- :config
- (if ek-use-nerd-fonts ;; Check if nerd fonts are being used
- (setopt magit-format-file-function #'magit-format-file-nerd-icons)) ;; Turns on magit nerd-icons
- :defer t)
+(use-package magit
+ :ensure t
+ :straight t
+ :config
+ (if ek-use-nerd-fonts ;; Check if nerd fonts are being used
+ (setopt magit-format-file-function #'magit-format-file-nerd-icons)) ;; Turns on magit nerd-icons
+ :defer t)
#+end_src
* indent guide
#+begin_src emacs-lisp
-
- (use-package indent-guide
- :defer t
- :straight t
- :ensure t
- :hook
- (prog-mode . indent-guide-mode) ;; Activate indent-guide in programming modes.
- :config
- (setq indent-guide-char "│")) ;; Set the character used for the indent guide.
-#+end_src
-* f
-
-#+begin_src emacs-lisp
-
-;; (u se-package add-node-modules-path
- ;; :ensure t
- ;; :straight t
- ;; :defer t
- ;; :custom
- ;; ;; Makes sure you are using the local bin for your
- ;; ;; node project. Local eslint, typescript server...
- ;; (eval-after-load 'typescript-ts-mode
- ;; '(add-hook 'typescript-ts-mode-hook #'add-node-modules-path))
- ;; (eval-after-load 'tsx-ts-mode
- ;; '(add-hook 'tsx-ts-mode-hook #'add-node-modules-path))
- ;; (eval-after-load 'typescriptreact-mode
- ;; '(add-hook 'typescriptreact-mode-hook #'add-node-modules-path))
- ;; (eval-after-load 'js-mode
- ;; '(add-hook 'js-mode-hook #'add-node-modules-path)))
+(use-package indent-guide
+ :defer t
+ :straight t
+ :ensure t
+ :hook
+ (prog-mode . indent-guide-mode) ;; Activate indent-guide in programming modes.
+ :config
+ (setq indent-guide-char "│")) ;; Set the character used for the indent guide.
#+end_src
* general
@@ -1004,13 +1009,13 @@ completion-category-overrides '((file (styles partial-completion))))) ;; Customi
:init
(setq evil-want-integration t)
(setq evil-want-keybinding nil)
- (setq evil-want-C-u-delete t) ;; Makes C-u delete on insert mode
- (setq evil-want-C-u-scroll t) ;; Makes C-u delete on insert mode
-
+ (setq evil-want-C-u-delete t)
+ (setq evil-want-C-u-scroll t)
+ (setq evil-undo-system 'undo-tree)
:config
- (evil-mode 1))
-
-
+ (evil-mode 1)
+ (define-key evil-normal-state-map "u" 'undo-tree-undo)
+ (define-key evil-normal-state-map (kbd "C-r") 'undo-tree-redo))
#+end_src
** smart pairs
@@ -1018,19 +1023,14 @@ completion-category-overrides '((file (styles partial-completion))))) ;; Customi
#+begin_src emacs-lisp
(use-package smartparens
:ensure t
- :hook ((emacs-lisp-mode . smartparens-strict-mode)
- (lisp-mode . smartparens-strict-mode)
- (scheme-mode . smartparens-strict-mode)
- (clojure-mode . smartparens-strict-mode))
+ :init
+ (smartparens-global-mode 1)
:config
- (require 'smartparens-config)
- (smartparens-mode))
-
+ (require 'smartparens-config))
(use-package evil-smartparens
:ensure t
:after evil-collection
:hook (smartparens-global-mode . evil-smartparens-mode))
-
#+end_src
** evil packages
@@ -1096,39 +1096,29 @@ completion-category-overrides '((file (styles partial-completion))))) ;; Customi
avy-case-fold-search t
avy-timeout-seconds 0.3
avy-style 'at-full
- avy-keys '(?a ?s ?d ?f ?g ?h ?j ?k ?l ?q ?w ?e ?r ?t ?y ?u ?i ?o ?p))
+ avy-keys '(?a ?s ?d ?f ?g ?h ?j ?k ?l))
(evil-define-avy-motion evil-avy-goto-char-timer inclusive))
#+end_src
-** avy flash behaviour
-
-#+begin_src emacs-lisp
-
-#+end_src
* undo-tree
#+begin_src emacs-lisp
- (use-package undo-tree
- :defer t
- :ensure t
- :straight t
- :hook
- (after-init . global-undo-tree-mode)
- :init
- (setq undo-tree-visualizer-timestamps t
- undo-tree-visualizer-diff t
- ;; Increase undo limits to avoid losing history due to Emacs' garbage collection.
- ;; These values can be adjusted based on your needs.
- ;; 10X bump of the undo limits to avoid issues with premature
- ;; Emacs GC which truncates the undo history very aggressively.
- undo-limit 800000 ;; Limit for undo entries.
- undo-strong-limit 12000000 ;; Strong limit for undo entries.
- undo-outer-limit 120000000) ;; Outer limit for undo entries.
- :config
- ;; Set the directory where `undo-tree' will save its history files.
- ;; This keeps undo history across sessions, stored in a cache directory.
- (setq undo-tree-history-directory-alist '(("." . "~/.emacs.d/.cache/undo"))))
+(use-package undo-tree
+ :defer t
+ :ensure t
+ :straight t
+ :hook (after-init . global-undo-tree-mode)
+ :init
+ (setq undo-tree-visualizer-timestamps t
+ undo-tree-visualizer-diff t
+ undo-tree-auto-save-history nil
+ undo-tree-history-directory-alist nil
+ undo-limit 800000
+ undo-strong-limit 12000000
+ undo-outer-limit 120000000)
+ :config
+ (setq undo-tree-mode-lighter ""))
#+end_src
* Rainbow Delimiter
@@ -1141,6 +1131,7 @@ completion-category-overrides '((file (styles partial-completion))))) ;; Customi
:hook
(prog-mode . rainbow-delimiters-mode))
#+end_src
+
* dotenv-mode
#+begin_src emacs-lisp
@@ -1157,7 +1148,8 @@ completion-category-overrides '((file (styles partial-completion))))) ;; Customi
(use-package envrc
:hook (after-init . envrc-global-mode))
#+end_src
-* pulsar /disabled/
+
+* pulsar
#+begin_src emacs-lisp
(use-package pulsar
@@ -1183,29 +1175,7 @@ completion-category-overrides '((file (styles partial-completion))))) ;; Customi
(add-to-list 'pulsar-pulse-functions 'diff-hl-next-hunk)
(add-to-list 'pulsar-pulse-functions 'diff-hl-previous-hunk))
#+end_src
-* doom modeline /disabled/
-#+begin_src emacs-lisp
- ;;; DOOM MODELINE
- ;; The `doom-modeline' package provides a sleek, modern mode-line that is visually appealing
- ;; and functional. It integrates well with various Emacs features, enhancing the overall user
- ;; experience by displaying relevant information in a compact format.
- ;; (use-package doom-modeline
- ;; :ensure t
- ;; :straight t
- ;; :defer t
- ;; :custom
- ;; (doom-modeline-buffer-file-name-style 'buffer-name) ;; Set the buffer file name style to just the buffer name (without path).
- ;; (doom-modeline-project-detection 'project) ;; Enable project detection for displaying the project name.
- ;; (doom-modeline-buffer-name t) ;; Show the buffer name in the mode line.
- ;; (doom-modeline-vcs-max-length 25) ;; Limit the version control system (VCS) branch name length to 25 characters.
- ;; :config
- ;; (if ek-use-nerd-fonts ;; Check if nerd fonts are being used.
- ;; (setq doom-modeline-icon t) ;; Enable icons in the mode line if nerd fonts are used.
- ;; (setq doom-modeline-icon nil)) ;; Disable icons if nerd fonts are not being used.
- ;; :hook
- ;; (after-init . doom-modeline-mode))
-#+end_src
* evil-org
#+begin_src emacs-lisp
@@ -1218,6 +1188,7 @@ completion-category-overrides '((file (styles partial-completion))))) ;; Customi
(require 'evil-org-agenda)
(evil-org-agenda-set-keys))
#+end_src
+
* nerd-icons
#+begin_src emacs-lisp
@@ -1252,6 +1223,7 @@ completion-category-overrides '((file (styles partial-completion))))) ;; Customi
(nerd-icons-completion-mode) ;; Activate nerd icons for completion interfaces.
(add-hook 'marginalia-mode-hook #'nerd-icons-completion-marginalia-setup)) ;; Setup icons in the marginalia mode for enhanced completion display.
#+end_src
+
* catppuccin theme
#+begin_src emacs-lisp
@@ -1301,23 +1273,13 @@ completion-category-overrides '((file (styles partial-completion))))) ;; Customi
;;; init.el ends here
#+end_src
-#+begin_src emacs-lisp
- (use-package org-modern
- :ensure t
- :straight t
- )
- (with-eval-after-load 'org (global-org-modern-mode))
-
- (setq org-modern-star 'fold)
- (setq org-modern-fold-stars '(("◉" . "○")))
- (setq org-modern-star 'replace)
- (setq org-modern-replace-stars "◉○◉○◉")
-#+end_src
* configuration/soph
+
** soph-modeline
+
*** Battery Faces
- Extracted from doom modeline
+Extracted from doom modeline
#+begin_src emacs-lisp
(require 'battery)
@@ -1347,9 +1309,10 @@ completion-category-overrides '((file (styles partial-completion))))) ;; Customi
'((t :inherit error))
"Face for battery error.")
#+end_src
+
*** Battery Update Function
- Function that updates the battery string with nerd icons.
+Function that updates the battery string with nerd icons.
#+begin_src emacs-lisp
(defvar my-battery-string nil)
@@ -1427,6 +1390,7 @@ completion-category-overrides '((file (styles partial-completion))))) ;; Customi
(concat (propertize icon 'help-echo help-echo)
(propertize text 'face face 'help-echo help-echo))))))
#+end_src
+
*** Battery Override
Replaces the default battery display with the custom version.
@@ -1440,6 +1404,7 @@ Replaces the default battery display with the custom version.
(add-hook 'display-battery-mode-hook #'my-override-battery)
#+end_src
+
*** Header Line Format
The Modeline itself with Battery and Time on the right, Line:Column after VC on the left.
@@ -1481,6 +1446,7 @@ mode-line-buffer-identification
(setq-default mode-line-format nil)
#+end_src
+
** hide modeline
#+begin_src emacs-lisp
@@ -1489,50 +1455,41 @@ mode-line-buffer-identification
:defer t
:bind (:map custom-bindings-map ("C-c h m" . hide-mode-line-mode)))
#+end_src
+
** adaptive wrap
#+begin_src emacs-lisp
(use-package adaptive-wrap
- :defer t
- :hook (visual-line-mode . adaptive-wrap-prefix-mode))
+ :ensure t
+ :hook ((text-mode . adaptive-wrap-prefix-mode))
+ :config
+ (add-hook 'org-mode-hook
+ (lambda ()
+ (when (bound-and-true-p adaptive-wrap-prefix-mode)
+ (adaptive-wrap-prefix-mode -1)))))
#+end_src
+
** gpg home
#+begin_src emacs-lisp
(setq package-gnupghome-dir "~/.gnupg")
#+end_src
+
** cursor
#+begin_src emacs-lisp
-(blink-cursor-mode 0)
+(blink-cursor-mode 0)
(setq-default cursor-type 'bar)
#+end_src
-** highlight long lines
-
-#+begin_src emacs-lisp
-;; (setq my-whitespace-style '(face tabs lines-tail) ;; ⚠️ DEAKTIVIERT
-;; whitespace-style my-whitespace-style ;; ⚠️ DEAKTIVIERT
-;; whitespace-line-column 120 ;; ⚠️ DEAKTIVIERT
-;; fill-column 120 ;; ⚠️ DEAKTIVIERT
-;; whitespace-display-mappings ;; ⚠️ DEAKTIVIERT
-;; '((space-mark 32 [183] [46]) ;; ⚠️ DEAKTIVIERT
-;; (newline-mark 10 [36 10]) ;; ⚠️ DEAKTIVIERT
-;; (tab-mark 9 [9655 9] [92 9]))) ;; ⚠️ DEAKTIVIERT
-;; in e.g. clojure-mode-hook
-;; (whitespace-mode 1)
-;; or globally
-;; (global-whitespace-mode 1)
-;; (add-hook 'prog-mode 'whitespace-mode) ;; ⚠️ KOMPLETT DEAKTIVIERT - verursacht org-mode Probleme
-#+end_src
** default fixed, variable fonts
#+begin_src emacs-lisp
(defvar cashmere/font-height 170)
-(when (member "Maple Mono NF" (font-family-list))
- (set-face-attribute 'default nil :font "Maple Mono NF" :height cashmere/font-height)
- (set-face-attribute 'fixed-pitch nil :family "Maple Mono NF" :height cashmere/font-height))
+(when (member "Fragment Mono" (font-family-list))
+ (set-face-attribute 'default nil :font "Fragment Mono" :height cashmere/font-height)
+ (set-face-attribute 'fixed-pitch nil :family "Fragment Mono" :height cashmere/font-height))
(when (member "Maple Mono NF" (font-family-list))
(set-face-attribute 'variable-pitch nil :family "Maple Mono NF" :height cashmere/font-height))
@@ -1541,11 +1498,11 @@ mode-line-buffer-identification
** mixed pitch fonts (package)
#+begin_src emacs-lisp
- (use-package mixed-pitch
- :straight t
- :defer t
- :hook ((org-mode . mixed-pitch-mode)
- (LaTeX-mode . mixed-pitch-mode)))
+(use-package mixed-pitch
+ :straight t
+ :defer t
+ :hook ((org-mode . mixed-pitch-mode)
+ (LaTeX-mode . mixed-pitch-mode)))
#+end_src
* autothemer
@@ -1578,6 +1535,7 @@ mode-line-buffer-identification
;; Corrects (and improves) org-mode's native fontification.
(doom-themes-org-config))
#+end_src
+
* dirvish
#+begin_src emacs-lisp
@@ -1615,9 +1573,20 @@ mode-line-buffer-identification
(setq-default olivetti-body-width 100)
(define-globalized-minor-mode my-global-olivetti-mode olivetti-mode
(lambda () (olivetti-mode 1)))
+(my/centered-cursor)
(my-global-olivetti-mode)
#+end_src
+
+* org modern indent
+
+#+begin_src emacs-lisp
+(use-package org-modern-indent
+ :straight (:host github :repo "jdtsmith/org-modern-indent")
+ :hook (org-mode . org-modern-indent-mode))
+#+end_src
+
* declutter
+
** ibuffer
#+begin_src emacs-lisp
@@ -1639,12 +1608,7 @@ mode-line-buffer-identification
"^\\*ts-ls\\*$"
"^\\*ts-ls::stderr\\*$"))
#+end_src
-* bufler
-#+begin_src emacs-lisp
- (use-package bufler
- :defer t)
-#+end_src
* eat
#+begin_src emacs-lisp
@@ -1661,6 +1625,7 @@ mode-line-buffer-identification
(eat-global-mode)
(setq eat-kill-buffer-on-exit t)))
#+end_src
+
* projectile
#+begin_src emacs-lisp
@@ -1675,6 +1640,7 @@ mode-line-buffer-identification
projectile-sort-order 'recentf
projectile-require-project-root nil))
#+end_src
+
** consult-projectile
#+begin_src emacs-lisp
@@ -1686,6 +1652,7 @@ mode-line-buffer-identification
:config
(setq consult-project-function #'projectile-project-root))
#+end_src
+
* pass
#+begin_src emacs-lisp
@@ -1693,6 +1660,7 @@ mode-line-buffer-identification
:ensure t
:defer t)
#+end_src
+
* zoom
#+begin_src emacs-lisp
@@ -1700,35 +1668,29 @@ mode-line-buffer-identification
:ensure t
:defer t)
#+end_src
+
* pdf-tools
#+begin_src emacs-lisp
(use-package pdf-tools
- :ensure t)
+ :ensure t
+ :magic ("%PDF" . pdf-view-mode)
+ :config
+ (pdf-tools-install :no-query)
+ :hook (pdf-view-mode . (lambda () (display-line-numbers-mode -1))))
#+end_src
-* keybindings
-** disable frame
- #+begin_src emacs-lisp
- ;; (setq )
- #+end_src
+* keybindings
** global leader (SPC) kill ring
#+begin_src emacs-lisp
-(defun my/smart-find-file ()
- (interactive)
- (if (projectile-project-p)
- (projectile-find-file)
- (consult-buffer)))
-
(my-leader
"sp" '(consult-ripgrep :wk "search project")
"/" '(consult-line :wk "search buffer")
"." '(find-file :wk "find file")
"," '(bufler-switch-buffer :wk "switch buffer")
- "SPC" '(my/smart-find-file :wk "find file/buffer")
":" (lambda () (interactive) (execute-extended-command nil))
"d" '(:ignore t :wk "denote")
@@ -1820,6 +1782,8 @@ mode-line-buffer-identification
** local leader (,)
+This is my own personal local leader configuration.
+
#+begin_src emacs-lisp
(my-local-leader
"a" '(org-agenda :wk "org agenda")
@@ -1830,6 +1794,8 @@ mode-line-buffer-identification
** normal state
+Here we configure the keymaps for keymaps in normal state.
+
#+begin_src emacs-lisp
(general-def 'normal 'override
"]d" 'flymake-goto-next-error
@@ -1862,6 +1828,7 @@ mode-line-buffer-identification
(region-beginning)
(region-end)))))
#+end_src
+
** avy
#+begin_src emacs-lisp
@@ -1874,6 +1841,7 @@ mode-line-buffer-identification
(maximum-scroll-margin 0))
(call-interactively 'evil-avy-goto-char-2 ))))
#+end_src
+
** dirvish
#+begin_src emacs-lisp