27 lines
668 B
EmacsLisp
27 lines
668 B
EmacsLisp
|
;;;; Python configuration.
|
||
|
(require 'jenga-functions)
|
||
|
(instl 'elpy)
|
||
|
(instl 'jupyter)
|
||
|
(instl 'ein)
|
||
|
(instl 'py-autopep8)
|
||
|
(instl 'yasnippet)
|
||
|
|
||
|
(elpy-enable)
|
||
|
|
||
|
(add-hook 'elpy-mode-hook 'py-autopep8-enable-on-save)
|
||
|
|
||
|
;; Enable Flycheck
|
||
|
(when (require 'flycheck nil t)
|
||
|
(setq elpy-modules (delq 'elpy-module-flymake elpy-modules))
|
||
|
(add-hook 'elpy-mode-hook 'flycheck-mode))
|
||
|
|
||
|
;; Use IPython for REPL
|
||
|
(setq python-shell-interpreter "jupyter"
|
||
|
python-shell-interpreter-args "console --simple-prompt"
|
||
|
python-shell-prompt-detect-failure-warning nil)
|
||
|
|
||
|
(add-to-list 'python-shell-completion-native-disabled-interpreters
|
||
|
"jupyter")
|
||
|
|
||
|
(provide 'jenga-python)
|