diff --git a/emacs/.emacs.d/config/init-completion.el b/emacs/.emacs.d/config/init-completion.el index c0ee51f..509210c 100644 --- a/emacs/.emacs.d/config/init-completion.el +++ b/emacs/.emacs.d/config/init-completion.el @@ -61,6 +61,7 @@ ;; Consult adds a bunch of completing-read based utilities (use-package consult :general - ([remap switch-to-buffer] #'consult-buffer)) + ([remap switch-to-buffer] #'consult-buffer) + ([remap imenu] #'consult-imenu)) (provide 'init-completion) diff --git a/emacs/.emacs.d/config/init-ide.el b/emacs/.emacs.d/config/init-ide.el new file mode 100644 index 0000000..6faf127 --- /dev/null +++ b/emacs/.emacs.d/config/init-ide.el @@ -0,0 +1,27 @@ +;; IDE features + +;; Company-mode provides inline autocompletion +(use-package company + :hook (after-init . global-company-mode)) + +;; Flycheck gives you error squigglies +(use-package flycheck + :hook (after-init . global-flycheck-mode) + :custom + (flycheck-disabled-checkers '(emacs-lisp-checkdoc emacs-lisp))) + +;; Quick file overview for supported modes +(use-package imenu + :straight (:type built-in) + :general + (leader-map "m" #'imenu)) + +;; Find definition/references +(use-package xref + :straight (:type built-in) + :general + (normal "M-." #'xref-find-definitions) + (normal "M-," #'xref-pop-marker-stack) + (normal "M-r" #'xref-find-references)) + +(provide 'init-ide) diff --git a/emacs/.emacs.d/init.el b/emacs/.emacs.d/init.el index c0851ff..11fd82a 100644 --- a/emacs/.emacs.d/init.el +++ b/emacs/.emacs.d/init.el @@ -19,6 +19,18 @@ (straight-use-package 'use-package) (setq straight-use-package-by-default t) +;; Fix $PATH +(use-package exec-path-from-shell + :hook (after-init . exec-path-from-shell-initialize) + :custom + (exec-path-from-shell-variables '("PATH" "MANPATH" "LEDGER_FILE" "LOLA_HOME" + "MODELS_HOME" "LOLA_TRAVEL_SERVICE_HOME" "WORKON_HOME" + "PIPENV_VERBOSITY" "PIPENV_DONT_LOAD_ENV" + "PIPENV_MAX_DEPTH" "PYENV_ROOT" "KOPS_STATE_STORE" + "PLAID_CLIENT_ID" "PLAID_SECRET" "PLAID_ENVIRONMENT")) + (exec-path-from-shell-check-startup-files nil)) + + ;; Don't use this file as the custom-file (setq custom-file (expand-file-name "custom.el" user-emacs-directory)) @@ -40,6 +52,7 @@ (require 'init-ui) (require 'init-projects) (require 'init-git) +(require 'init-ide) ;; Load the custom file (when (file-exists-p custom-file)