summaryrefslogtreecommitdiff
path: root/.emacs.d/init.el
diff options
context:
space:
mode:
authorSteph Enders <steph@senders.io>2023-03-31 10:40:22 -0400
committerSteph Enders <steph@senders.io>2023-03-31 10:40:22 -0400
commitcd734d9a27b28ae2ba68ca5acf945c9bc1b94b1d (patch)
tree2bea0749e375968db2d8190287a131c597855312 /.emacs.d/init.el
parentfc310984a9d11bef8c843a041dc88be4b56e04f1 (diff)
Install lsp packages for IDE support
Now I have an IDE!!! Look at: https://emacs-lsp.github.io/lsp-mode/ for information and such - will contain the necessary out-links to anything else I'll need :)
Diffstat (limited to '.emacs.d/init.el')
-rw-r--r--.emacs.d/init.el15
1 files changed, 9 insertions, 6 deletions
diff --git a/.emacs.d/init.el b/.emacs.d/init.el
index 116ff79..5192c51 100644
--- a/.emacs.d/init.el
+++ b/.emacs.d/init.el
@@ -1,7 +1,7 @@
-;; load plugins
+;; load any plugins / call boostrapping code (straight)
(when (file-exists-p "~/.emacs.d/plugins.el")
(load "~/.emacs.d/plugins.el"))
-
+;; install packages
(when (file-exists-p "~/.emacs.d/packages.el")
(load "~/.emacs.d/packages.el"))
@@ -17,13 +17,16 @@
(setq inhibit-startup-screen t)
;; Mode hooks
;;; show line numbers
-;;; (global-display-line-numbers) ; we can set this if we find we want it for all buffers
(add-hook 'prog-mode-hook (lambda () (display-line-numbers-mode)
- (visual-line-mode)
- (visual-fill-column-mode)))
+ (visual-line-mode)))
(add-hook 'text-mode-hook (lambda () (display-line-numbers-mode)
(visual-line-mode)
(visual-fill-column-mode)))
+;; lsp-hooks
+(add-hook 'c++-mode-hook (lambda () (lsp)(company-mode)(yas-minor-mode)))
+(add-hook 'python-mode-hook (lambda () (lsp)(comapny-mode)))
+(add-hook 'java-mode-hook (lambda () (lsp)(comapny-mode)))
+(add-hook 'c-mode-hook (lambda () (lsp)(company-mode)))
;; Idiomdrottning and bad-emacs-defaults fixes
(global-set-key [(control h)] 'delete-backward-char)
@@ -54,4 +57,4 @@
(global-set-key "\C-cl" 'use-light-theme)
(global-set-key "\C-cd" 'use-dark-theme)
-
+(setq lsp-keymap-prefix "C-s-l")