mirror of
https://github.com/balkian/dotfiles.git
synced 2024-11-22 04:02:28 +00:00
25 lines
812 B
EmacsLisp
25 lines
812 B
EmacsLisp
|
(require 'python)
|
||
|
(setq
|
||
|
python-shell-interpreter "ipython"
|
||
|
python-shell-interpreter-args "--pylab"
|
||
|
python-shell-prompt-regexp "In \\[[0-9]+\\]: "
|
||
|
python-shell-prompt-output-regexp "Out\\[[0-9]+\\]: "
|
||
|
python-shell-completion-setup-code
|
||
|
"from IPython.core.completerlib import module_completion"
|
||
|
python-shell-completion-module-string-code
|
||
|
"';'.join(module_completion('''%s'''))\n"
|
||
|
python-shell-completion-string-code
|
||
|
"';'.join(get_ipython().Completer.all_completions('''%s'''))\n")
|
||
|
|
||
|
(add-hook 'python-mode-hook 'auto-complete-mode)
|
||
|
(add-hook 'python-mode-hook '(lambda () (require 'nose)))
|
||
|
(add-hook 'python-mode-hook 'jedi:setup)
|
||
|
|
||
|
(eval-after-load "python"
|
||
|
'(progn
|
||
|
(define-key python-mode-map (kbd "C-c C-d") 'helm-pydoc)))
|
||
|
|
||
|
(setq jedi:complete-on-dot t)
|
||
|
|
||
|
(provide 'config-python)
|