mirror of
https://github.com/Hopiu/linkchecker.git
synced 2026-05-10 07:34:44 +00:00
Simplify the warning doc string construction and sanitize the configuration at end of option reading.
This commit is contained in:
parent
3775f18621
commit
b6b4a8ca29
1 changed files with 5 additions and 3 deletions
|
|
@ -188,9 +188,9 @@ none Logs nothing. Suitable for debugging or checking the exit code.
|
|||
Warnings = _(r"""IGNORE WARNINGS
|
||||
The following warnings are recognized in the 'ignorewarnings' config
|
||||
file entry:
|
||||
""")
|
||||
for tag, desc in sorted(linkcheck.checker.const.Warnings.items()):
|
||||
Warnings += u" o %s\n %s\n" % (tag, desc)
|
||||
""") + \
|
||||
"\n".join([u" o %s\n %s" % (tag, desc) \
|
||||
for tag, desc in sorted(linkcheck.checker.const.Warnings.items())])
|
||||
|
||||
|
||||
def print_version ():
|
||||
|
|
@ -743,6 +743,8 @@ for prefix in ("checkhtml", "checkcss"):
|
|||
option = "%s%s" % (prefix, suffix)
|
||||
if getattr(options, option) is not None:
|
||||
config[option] = getattr(options, option)
|
||||
# now sanitize the configuration
|
||||
config.sanitize()
|
||||
|
||||
log.debug(LOG_CMDLINE, "configuration: %s", pprint.pformat(config.items()))
|
||||
# warn about sitemap loggers and complete output
|
||||
|
|
|
|||
Loading…
Reference in a new issue