summary refs log tree commit diff
path: root/config/init-python.el
diff options
context:
space:
mode:
authorFranck Cuny <franck@fcuny.net>2024-04-06 11:22:57 -0700
committerFranck Cuny <franck@fcuny.net>2024-04-06 11:22:57 -0700
commit7c5780a719565630f58e7751afa8c7e458c49871 (patch)
treef8863ebcbd4a1e551a63374b3fee589affca1393 /config/init-python.el
parentmove some display stuff (diff)
downloademacs.d-7c5780a719565630f58e7751afa8c7e458c49871.tar.gz
a org file is definitely not the way for me
Diffstat (limited to 'config/init-python.el')
-rw-r--r--config/init-python.el28
1 files changed, 28 insertions, 0 deletions
diff --git a/config/init-python.el b/config/init-python.el
new file mode 100644
index 0000000..0927dd2
--- /dev/null
+++ b/config/init-python.el
@@ -0,0 +1,28 @@
+;;; init-python.el --- Configure python -*- lexical-binding: t -*-
+;; Author: Franck Cuny <franck@fcuny.net>
+
+;;; Commentary:
+
+;; All python related things
+
+;;; Code:
+
+(use-package python-mode
+  :hook ((python-mode . tree-sitter-hl-mode)
+         (python-mode . eglot-ensure))
+  :interpreter "python"
+  :bind (:map python-mode-map
+              ("C-c c")
+              ("C-c C-z" . python-shell)))
+
+(use-package blacken
+  :ensure t
+  :hook (python-mode . blacken-mode))
+
+(use-package py-isort
+  :ensure t
+  :commands (py-isort-buffer py-isort-region))
+
+(provide 'init-python)
+
+;;; init-python.el ends here