updated
This commit is contained in:
parent
ec25a6e21a
commit
4887d23af3
130
init.el
130
init.el
|
@ -78,6 +78,7 @@
|
||||||
|
|
||||||
;; set up font ligatures
|
;; set up font ligatures
|
||||||
(use-package pragmatapro-lig
|
(use-package pragmatapro-lig
|
||||||
|
:if window-system
|
||||||
:straight (pragmatapro-lig :type git
|
:straight (pragmatapro-lig :type git
|
||||||
:host github
|
:host github
|
||||||
:repo "lumiknit/emacs-pragmatapro-ligatures")
|
:repo "lumiknit/emacs-pragmatapro-ligatures")
|
||||||
|
@ -251,66 +252,89 @@
|
||||||
:bind (("M-/" . company-complete))
|
:bind (("M-/" . company-complete))
|
||||||
:config (add-hook 'after-init-hook 'global-company-mode))
|
:config (add-hook 'after-init-hook 'global-company-mode))
|
||||||
|
|
||||||
(if (equal(system-name) "cult")
|
(setq use-lsp (equal (system-name) "cult"))
|
||||||
(progn
|
|
||||||
|
|
||||||
;; Posframe is a pop-up tool that must be manually installed for dap-mode
|
;; when not using lsp use hippie expand
|
||||||
(use-package posframe)
|
(when (not use-lsp)
|
||||||
|
;; hippie expand stuff: M-/ to expand things
|
||||||
|
(bind-key "M-/" 'hippie-expand)
|
||||||
|
(defun sanityinc/dabbrev-friend-buffer (other-buffer)
|
||||||
|
(< (buffer-size other-buffer) (* 1 1024 1024)))
|
||||||
|
(setq dabbrev-friend-buffer-function 'sanityinc/dabbrev-friend-buffer)
|
||||||
|
(setq hippie-expand-try-functions-list
|
||||||
|
'(try-expand-all-abbrevs
|
||||||
|
try-complete-file-name-partially
|
||||||
|
try-complete-file-name
|
||||||
|
try-expand-dabbrev
|
||||||
|
try-expand-dabbrev-from-kill
|
||||||
|
try-expand-dabbrev-all-buffers
|
||||||
|
try-expand-list
|
||||||
|
try-expand-line
|
||||||
|
try-complete-lisp-symbol-partially
|
||||||
|
try-complete-lisp-symbol)))
|
||||||
|
|
||||||
;; Use the Debug Adapter Protocol for running tests and debugging
|
;; Posframe is a pop-up tool that must be manually installed for dap-mode
|
||||||
(use-package dap-mode
|
(use-package posframe
|
||||||
:hook (lsp-mode . dap-mode)
|
:if use-lsp)
|
||||||
(lsp-mode . dap-ui-mode))
|
|
||||||
|
|
||||||
(use-package flycheck
|
;; Use the Debug Adapter Protocol for running tests and debugging
|
||||||
:init (global-flycheck-mode))
|
(use-package dap-mode
|
||||||
|
:if use-lsp
|
||||||
|
:hook (lsp-mode . dap-mode)
|
||||||
|
(lsp-mode . dap-ui-mode))
|
||||||
|
|
||||||
(use-package lsp-mode
|
(use-package flycheck
|
||||||
:ensure t
|
:if use-lsp
|
||||||
:config (setq lsp-headerline-breadcrumb-enable nil
|
:init (global-flycheck-mode))
|
||||||
lsp-keymap-prefix "C-c l"
|
|
||||||
lsp-enable-symbol-highlighting nil
|
|
||||||
;lsp-lens-enable nil
|
|
||||||
;lsp-signature-render-documentation nil
|
|
||||||
lsp-eldoc-enable-hover nil
|
|
||||||
;lsp-signature-auto-activate nil
|
|
||||||
;lsp-enable-file-watchers nil
|
|
||||||
read-process-output-max (* 1024 1024) ; 1M
|
|
||||||
lsp-modeline-diagnostics-enable nil
|
|
||||||
lsp-prefer-capf t
|
|
||||||
lsp-completion-provider :capf
|
|
||||||
lsp-completion-enable t
|
|
||||||
lsp-prefer-flymake nil)
|
|
||||||
;(setf (lsp--client-multi-root (gethash 'iph lsp-clients)) nil)
|
|
||||||
(define-key lsp-mode-map (kbd "C-c l") lsp-command-map)
|
|
||||||
:hook (lsp-mode . lsp-lens-mode)
|
|
||||||
(lsp-mode . lsp-enable-which-key-integration)
|
|
||||||
(scala-mode . lsp)
|
|
||||||
(rust-mode . lsp)
|
|
||||||
(java-mode . lsp))
|
|
||||||
|
|
||||||
(use-package lsp-metals
|
(use-package lsp-mode
|
||||||
:ensure t
|
:if use-lsp
|
||||||
:config (setq lsp-metals-server-args '("-J-Dmetals.allow-multiline-string-formatting=off")
|
:ensure t
|
||||||
lsp-metals-show-inferred-type nil
|
:config (setq lsp-headerline-breadcrumb-enable nil
|
||||||
lsp-metals-super-method-lenses-enabled nil
|
lsp-keymap-prefix "C-c l"
|
||||||
lsp-metals-show-implicit-arguments nil
|
lsp-enable-symbol-highlighting nil
|
||||||
lsp-meatals-show-implicit-conversions-and-classes nil))
|
;lsp-lens-enable nil
|
||||||
|
;lsp-signature-render-documentation nil
|
||||||
|
lsp-eldoc-enable-hover nil
|
||||||
|
;lsp-signature-auto-activate nil
|
||||||
|
;lsp-enable-file-watchers nil
|
||||||
|
read-process-output-max (* 1024 1024) ; 1M
|
||||||
|
lsp-modeline-diagnostics-enable nil
|
||||||
|
lsp-prefer-capf t
|
||||||
|
lsp-completion-provider :capf
|
||||||
|
lsp-completion-enable t
|
||||||
|
lsp-prefer-flymake nil)
|
||||||
|
;(setf (lsp--client-multi-root (gethash 'iph lsp-clients)) nil)
|
||||||
|
(define-key lsp-mode-map (kbd "C-c l") lsp-command-map)
|
||||||
|
:hook (lsp-mode . lsp-lens-mode)
|
||||||
|
(lsp-mode . lsp-enable-which-key-integration)
|
||||||
|
(scala-mode . lsp)
|
||||||
|
(rust-mode . lsp)
|
||||||
|
(java-mode . lsp))
|
||||||
|
|
||||||
(use-package lsp-ui
|
(use-package lsp-metals
|
||||||
:ensure t
|
:if use-lsp
|
||||||
:hook (lsp-mode . lsp-ui-mode)
|
:ensure t
|
||||||
:config (setq lsp-ui-doc-enable nil
|
:config (setq lsp-metals-server-args '("-J-Dmetals.allow-multiline-string-formatting=off")
|
||||||
lsp-ui-sideline-enable t
|
lsp-metals-show-inferred-type nil
|
||||||
;lsp-ui-sideline-show-code-actions nil
|
lsp-metals-super-method-lenses-enabled nil
|
||||||
lsp-ui-sideline-diagnostic-max-line-length 60
|
lsp-metals-show-implicit-arguments nil
|
||||||
lsp-ui-sideline-diagnostic-max-lines 6))
|
lsp-meatals-show-implicit-conversions-and-classes nil))
|
||||||
|
|
||||||
(use-package lsp-java
|
(use-package lsp-ui
|
||||||
:ensure t
|
:if use-lsp
|
||||||
:config (add-hook 'java-mode-hook 'lsp))
|
:ensure t
|
||||||
|
:hook (lsp-mode . lsp-ui-mode)
|
||||||
|
:config (setq lsp-ui-doc-enable nil
|
||||||
|
lsp-ui-sideline-enable t
|
||||||
|
;lsp-ui-sideline-show-code-actions nil
|
||||||
|
lsp-ui-sideline-diagnostic-max-line-length 60
|
||||||
|
lsp-ui-sideline-diagnostic-max-lines 6))
|
||||||
|
|
||||||
))
|
(use-package lsp-java
|
||||||
|
:if use-lsp
|
||||||
|
:ensure t
|
||||||
|
:config (add-hook 'java-mode-hook 'lsp))
|
||||||
|
|
||||||
;; projectile
|
;; projectile
|
||||||
(use-package projectile
|
(use-package projectile
|
||||||
|
@ -365,8 +389,8 @@
|
||||||
:bind (("C-x g" . magit-status)
|
:bind (("C-x g" . magit-status)
|
||||||
("s-b" . magit-blame)))
|
("s-b" . magit-blame)))
|
||||||
|
|
||||||
;; org roam
|
|
||||||
(use-package org-roam
|
(use-package org-roam
|
||||||
|
:if (equal (system-name) "cult")
|
||||||
:config (setq org-roam-directory "~/org/")
|
:config (setq org-roam-directory "~/org/")
|
||||||
(org-roam-db-autosync-mode))
|
(org-roam-db-autosync-mode))
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue