diff options
author | Deepesh Pathak <deepshpathak@gmail.com> | 2018-01-30 03:33:01 +0530 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2018-04-22 20:48:44 -0400 |
commit | 48092540d09d87d6385b227fe255921285371838 (patch) | |
tree | 149d128ed6b8a38ebc6c0f872cc5a27dd6dae54a /Makefile.am | |
parent | 955f4d87414285ab7ab0ef6d01373e18871892d3 (diff) | |
download | tor-48092540d09d87d6385b227fe255921285371838.tar.gz tor-48092540d09d87d6385b227fe255921285371838.zip |
Add spell check to makefile to check for typos ticket#25024
- Use misspell to check for typos in codebase
- Add `make check-typos` to run the checks
- Add `check-typos` to `make check`
Diffstat (limited to 'Makefile.am')
-rw-r--r-- | Makefile.am | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/Makefile.am b/Makefile.am index 04ca88a236..b892c69f78 100644 --- a/Makefile.am +++ b/Makefile.am @@ -97,7 +97,7 @@ doxygen: test: all $(top_builddir)/src/test/test -check-local: check-spaces check-changes +check-local: check-spaces check-changes check-typos need-chutney-path: @if test ! -d "$$CHUTNEY_PATH"; then \ @@ -217,6 +217,26 @@ check-logs: $(top_srcdir)/scripts/maint/checkLogs.pl \ $(top_srcdir)/src/*/*.[ch] | sort -n +.PHONY: check-typos +check-typos: + @if test -x "`which misspell 2>&1;true`"; then \ + echo "Checking for Typos ..."; \ + (`which misspell` \ + $(top_srcdir)/src/**/*.[ch] \ + $(top_srcdir)/doc \ + $(top_srcdir)/contrib \ + $(top_srcdir)/scripts \ + $(top_srcdir)/README \ + $(top_srcdir)/ChangeLog \ + $(top_srcdir)/INSTALL \ + $(top_srcdir)/ReleaseNotes \ + $(top_srcdir)/LICENSE); \ + else \ + echo "Tor can use misspell to check for typos."; \ + echo "It seems that you don't have misspell installed."; \ + echo "You can install the latest version of misspell here: https://github.com/client9/misspell#install"; \ + fi + .PHONY: check-changes check-changes: if USEPYTHON |