I have ipython.el and python-mode.el installed in my path, and I have the following added to my init.el:
(autoload 'python-mode "python-mode" "Python editing mode." t)
(setq auto-mode-alist (cons '("\\.py$" . python-mode) auto-mode-alist))
(setq interpreter-mode-alist (cons '("python" . python-mode) interpreter-mode-alist))
(setq ipython-command "/Library/Frameworks/EPD64.framework/Versions/Current/bin/ipython")
(require 'ipython)
But python-mode insists on launching the python interpreter instead of ipython. Changing py-python-command doesn't help either.
How do I get Ipython to be the default?
:) Same question when I want to using ipython in emacs.
Infact, new python-mode provide another method to invoke ipython. You just simply call that method will solve this. (bind function to keys you need) You can using command:
M-x ipython
to using ipython
execute code in ipython by calling:
M-x py-execute-buffer-ipython
But, honestly, using ipython in emacs is slower and using
py-execute-buffer
in python-mode can handle almost all questions(easy to change code, move cursor or any requirements).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With