myint / scspell

Spell checker for source code
https://pypi.python.org/pypi/scspell3k
GNU General Public License v2.0
90 stars 20 forks source link

Add "base dicts" #7

Closed cassella closed 8 years ago

cassella commented 8 years ago

One or more --base-dict's may be specified on the command line. We search for tokens in these dicts, but do not add words to them.

--use-builtin-base-dict uses the dictionary.txt in SCSPELL_DATA_DIR as a base dict.

This allows a project-specific dictionary to be maintained containing only words from the project, without including the full 844K base dictionary and its license terms. E.g.

$ cd PROJECT $ scspell --override-dictionary .scspell/dictionary.txt \ --use-builtin-base-dict \ $PROJECT_FILES

Another benefit is that as scspell's dictionary is updated over time, scspell invoked with --use-builtin-base-dict will reflect the updated dictionary automatically.

cassella commented 8 years ago

This one should be more straightforward. :)

Once this is merged, I thought I might change the scspell invocation in "make check" to use this feature, so that things like "pelzl" and "myint" could be added to a local .scspell/dictionary.txt. That way every new developer can just run "make check" without building up their own ~/.scspell/dictionary.txt first.

BTW, why doesn't make check run pyflakes?

myint commented 8 years ago

I think we ought to make it run pyflakes.

myint commented 8 years ago

Thanks.