lesson_check.py: Exit with a status of 1 if something was wrong
## lesson-check-all : validate lesson Markdown, checking line lengths and trailing whitespace.
lesson-check-all :
- @bin/lesson_check.py -s . -p ${PARSER} -l -w
+ @bin/lesson_check.py -s . -p ${PARSER} -l -w --permissive
## unittest : run unit tests on checking tools.
unittest :
checker.check()
args.reporter.report()
+ if args.reporter.messages and not args.permissive:
+ exit(1)
def parse_args():
action="store_true",
dest='trailing_whitespace',
help='Check for trailing whitespace')
+ parser.add_option('--permissive',
+ default=False,
+ action="store_true",
+ dest='permissive',
+ help='Do not raise an error even if issues are detected')
args, extras = parser.parse_args()
require(args.parser is not None,