diff options
| author | jao <jao@gnu.org> | 2026-11-13 10:22:22 +0000 |
|---|---|---|
| committer | jao <jao@gnu.org> | 2026-11-13 10:22:22 +0000 |
| commit | 519aff06d86594e79af69faa34edeab5992a3df9 (patch) | |
| tree | 6cb819ef006d00c705d72eabe4d65a4177e33e1f /custom/jao-custom-programming.el | |
| parent | 6d38720fa34e9080bdb43119c98fcb06b8dc0364 (diff) | |
| download | elibs-519aff06d86594e79af69faa34edeab5992a3df9.tar.gz elibs-519aff06d86594e79af69faa34edeab5992a3df9.tar.bz2 | |
eglog/python nits
Diffstat (limited to 'custom/jao-custom-programming.el')
| -rw-r--r-- | custom/jao-custom-programming.el | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/custom/jao-custom-programming.el b/custom/jao-custom-programming.el index 0e749c0..034bb63 100644 --- a/custom/jao-custom-programming.el +++ b/custom/jao-custom-programming.el @@ -640,19 +640,21 @@ ;; python-shell-interpreter-args "run ipython -i --simple-prompt" python-shell-interpreter-args "run python -i") (defun jao-python-mode-hook () - (setq-local eglot-prefer-plaintext t) + (setq-local eglot-documentation-renderer t) (eglot-ensure)) - ;; (with-eval-after-load 'eglot - ;; (add-to-list 'eglot-server-programs - ;; '((python-base-mode :language-id "python") . ("ty" "server")))) + (with-eval-after-load 'eglot + (add-to-list 'eglot-server-programs + '((python-base-mode :language-id "python") . ("ty" "server")))) + + (defvar jao-python-history-file "~/.emacs.d/cache/python_history") (defun jao-inferior-python-mode-hook () - (setq-local comint-input-ring-file-name "~/.emacs.d/cache/python_history") + (setq-local comint-input-ring-file-name jao-python-history-file) (comint-read-input-ring 'silent) + ;; (add-hook 'kill-buffer-hook #'comint-write-input-ring nil t) (set-process-sentinel (get-buffer-process (current-buffer)) - (lambda (_p _e) (comint-write-input-ring))) - (add-hook 'kill-buffer-hook #'comint-write-input-ring nil t)) + (lambda (_p _e) (comint-write-input-ring)))) :hook ((python-base-mode . jao-python-mode-hook) (inferior-python-mode . jao-inferior-python-mode-hook)) |
