Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to spell check python docstring with emacs?

I'd like to run a spell checker on the docstrings of my Python code, if possible from within emacs.

I've found the ispell-check-comments setting which can be used to spell check only comments in code, but I was not able to target only the docstrings which are a fairly python-specific thing.

like image 348
gurney alex Avatar asked Mar 16 '10 14:03

gurney alex


1 Answers

I recommend you to try flyspell-mode. You could use something like:

(add-hook 'python-mode-hook 'flyspell-prog-mode)

in your Emacs configuration.

like image 105
Bozhidar Batsov Avatar answered Sep 30 '22 19:09

Bozhidar Batsov