From 231eb9379e95ba07d7b9cc71b0e3ff4e39265266 Mon Sep 17 00:00:00 2001 From: Julio Biason Date: Mon, 8 Mar 2021 13:57:42 -0300 Subject: [PATCH] Enabled Which-Key and trying to make LSP work with C-l --- emacs.d/init.el | 29 ++++++++++++++++++++++------- 1 file changed, 22 insertions(+), 7 deletions(-) diff --git a/emacs.d/init.el b/emacs.d/init.el index 6632e83..e30147f 100644 --- a/emacs.d/init.el +++ b/emacs.d/init.el @@ -41,7 +41,18 @@ :ensure t :bind (("\C-cl" . org-store-link) ("\C-ca" . org-agenda) - ("\C-cb" . org-iswtichb))) + ("\C-cb" . org-iswtichb)) + :init (add-hook 'org-mode-hook 'turn-on-auto-fill) + :config + (setq org-clock-persist 'history) + (setq org-todo-keywords '((sequence "TODO" "WORKING" "WAITING" "|" "DONE"))) + (org-clock-persistence-insinuate)) + +;; Which key shows commands after the prefix +(use-package which-key + :ensure t + :config + (which-key-mode)) ;; LanguageServer (use-package lsp-mode @@ -49,8 +60,12 @@ :hook ((python-mode . lsp) (rust-mode . lsp)) :commands lsp - :config (setq lsp-enable-indentation t - lsp-enable-on-type-formatting t)) + :init (global-unset-key "\C-l") + :config + (setq lsp-enable-indentation t + lsp-enable-on-type-formatting t + lsp-keymap-prefix "C-l") + (add-hook 'lsp-mode-hook #'lsp-enable-which-key-integration)) (use-package lsp-ui :commands lsp-ui-mode @@ -84,10 +99,10 @@ (define-key minibuffer-local-map (kbd "C-r") 'counsel-minibuffer-history) ) -;; powerline -(use-package powerline +;; doom-modeline +(use-package doom-modeline :ensure t - :config (powerline-center-theme)) + :init (doom-modeline-mode 1)) ;; colorschemes (use-package doom-themes @@ -115,7 +130,7 @@ (diff-hl-margin-mode 1) (diff-hl-flydiff-mode 1) -;; install editorconfig +;; editorconfig (use-package editorconfig :ensure t :config (editorconfig-mode 1))