sum more improvmeents

This commit is contained in:
Mars 2024-10-09 14:52:14 -04:00
parent 4a3e2d499a
commit 1350f5ea97
Signed by: pupbrained
GPG key ID: 874E22DF2F9DFCB5

View file

@ -155,8 +155,21 @@
(electric-indent-mode -1)
(electric-pair-mode 1)
(setq-default tab-width 2)
(setq-default indent-tabs-mode nil)
(setq-default evil-auto-indent t
indent-line-function 'evil-indent-line
indent-tabs-mode nil
tab-width 2
org-src-tab-acts-natively t
org-indent-indentation-per-level 2
org-indent-mode-turns-on-hiding-stars nil)
(defun indent-tabs-hook ()
(setq tab-width 2
indent-tabs-mode t
evil-auto-indent t
c-basic-offset 2))
(dolist (hook '(c++-mode-hook c-mode-hook c++-ts-mode-hook c-ts-mode-hook)) (add-hook hook 'indent-tabs-hook))
(use-package evil
:ensure t
@ -178,25 +191,6 @@
(evil-define-key 'normal 'global (kbd "gr") 'diff-hl-revert-hunk)
(evil-define-key 'normal 'global (kbd "gs") 'diff-hl-stage-current-hunk))
(defun my-set-indent-width ()
(setq-local tab-width 2)
(setq-local evil-shift-width 2)
(setq-local indent-tabs-mode nil))
(add-hook 'prog-mode-hook 'my-set-indent-width)
(defun my-org-src-edit-hook ()
"Set indent width for Org source blocks."
(setq indent-tabs-mode nil) ;; Use spaces instead of tabs
(setq tab-width 2)) ;; Set tab width to your desired value
(add-hook 'prog-mode-hook 'my-set-indent-width)
(defun my-org-src-edit-hook ()
"Set indent width for Org source blocks."
(setq indent-tabs-mode nil) ;; Use spaces instead of tabs
(setq tab-width 2)) ;; Set tab width to your desired value
(add-hook 'org-src-mode-hook 'my-org-src-edit-hook)
;; Set whitespace actions.
(setq-default whitespace-action
'(cleanup auto-cleanup))
@ -258,6 +252,13 @@
*** Eglot
#+begin_src emacs-lisp
(use-package markdown-mode
:ensure t
:mode ("README\\.md\\'" . gfm-mode)
:init (setq markdown-command "multimarkdown")
:bind (:map markdown-mode-map
("C-c C-e" . markdown-do)))
(use-package eglot-booster
:after eglot
:ensure (eglot-booster :type git :host github :repo "jdtsmith/eglot-booster")
@ -303,12 +304,16 @@
(c++-mode . eglot-ensure)
(c++-ts-mode . eglot-ensure)
(c3-ts-mode . eglot-ensure)
(rust-mode . eglot-ensure)
(go-mode . eglot-ensure)
(go-ts-mode . eglot-ensure))
(use-package rust-mode
:ensure t)
(use-package eldoc-box
:custom
(eldoc-box-max-pixel-width 1024)
(eldoc-box-max-pixel-width 1280)
:config
(setq eldoc-message-function #'ignore)
(setq eldoc-idle-delay 0)