1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-01-18 12:52:44 +01:00

dist/tools/codespell: add interactive mode

This commit is contained in:
Kaspar Schleiser 2019-10-23 21:15:42 +02:00
parent 496ae49692
commit f1799b9910

View File

@ -41,6 +41,15 @@ CODESPELL_OPTS+=" --check-hidden"
# "dout => doubt"
CODESPELL_OPTS+=" --ignore-words-list=ND,nd,wan,od,dout"
if [ "${CODESPELL_INTERACTIVE}" = "1" ]; then
# interactive mode
CODESPELL_OPTS+=" -w -i3"
exec ${CODESPELL_CMD} ${CODESPELL_OPTS} ${FILES}
# (exits shell)
fi
# non-interactive mode
# Filter-out all false positive raising "disabled due to" messages.
ERRORS=$(${CODESPELL_CMD} ${CODESPELL_OPTS} ${FILES} | grep -ve "disabled due to")