Wednesday 17 June 2009

emacs (< 22) & python

Download python-mode.el from http://sourceforge.net/projects/python-mode/
Add the following to the .emacs file:

(autoload 'python-mode "$PATH-TO-EMACS-SCRIPTS/python-mode" "Python Mode." t)
(add-to-list 'auto-mode-alist '("\\.py\\'" . python-mode))
(add-to-list 'interpreter-mode-alist '("python" . python-mode))

No comments: