diff options
author | Thanos Apollo <[email protected]> | 2023-09-08 15:26:14 +0300 |
---|---|---|
committer | Thanos Apollo <[email protected]> | 2023-09-08 15:26:14 +0300 |
commit | 9509eec0a0209b9eeb2e0185613d8ddace0e0f59 (patch) | |
tree | d901ee8255436f2a866c87ed7d8978e3fa65fa97 | |
parent | 8b8f09dec4bce11a934e93256c498bb223d41683 (diff) |
emacs: Update dev tools
- Add project-magit
- Use eglot for python
-rw-r--r-- | .emacs.d/modules/thanos-commands.el | 3 | ||||
-rw-r--r-- | .emacs.d/modules/thanos-dev.el | 9 |
2 files changed, 8 insertions, 4 deletions
diff --git a/.emacs.d/modules/thanos-commands.el b/.emacs.d/modules/thanos-commands.el index 8b3407e..8966d96 100644 --- a/.emacs.d/modules/thanos-commands.el +++ b/.emacs.d/modules/thanos-commands.el @@ -29,8 +29,6 @@ ;; ╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╱╰╯ ;;; Code: -(require 'gptel) - (defvar vm-directory "~/virtual-machines/") @@ -39,7 +37,6 @@ (let ((command-parts (split-string command "[ ]+"))) (apply #'call-process `(,(car command-parts) nil 0 nil ,@(cdr command-parts))))) - (defun thanos/emacs-keys () "Swap caps with ctrl." (interactive) diff --git a/.emacs.d/modules/thanos-dev.el b/.emacs.d/modules/thanos-dev.el index d80170e..f711bba 100644 --- a/.emacs.d/modules/thanos-dev.el +++ b/.emacs.d/modules/thanos-dev.el @@ -51,6 +51,13 @@ ;; Magit (require 'magit) +(defun project-magit () + "Run magit-status in the current project's root." + (interactive) + (magit-status (project-root (project-current t)))) + +(define-key project-prefix-map (kbd "s") 'project-magit) + (setf magit-display-buffer-function #'magit-display-buffer-same-window-except-diff-v1) (define-prefix-command 'thanos/magit) (global-set-key (kbd "C-c g") 'thanos/magit) @@ -103,7 +110,7 @@ (require 'python-mode) (add-to-list 'auto-mode-alist '("\\.py\\'" . python-mode)) -(add-hook 'python-mode 'lsp-mode) +(add-hook 'python-mode #'eglot) ;; json (require 'json-mode) |