Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Option to disable tidy code fixing option #693

Closed
sjeeva opened this issue Mar 13, 2018 · 2 comments
Closed

Option to disable tidy code fixing option #693

sjeeva opened this issue Mar 13, 2018 · 2 comments

Comments

@sjeeva
Copy link

sjeeva commented Mar 13, 2018

I am planning to run tidy in my devops pipeline and expect the developer to fix the error and warning.. Currently tidy doesn't print the current file name it is working and also the print out below message...

How do I disable tidy code fixing option and also disable below warning?

This document has errors that must be fixed before
using HTML Tidy to generate a tidied up version.

The alt attribute should be used to give a short description
of an image; longer descriptions should be given with the
longdesc attribute which takes a URL linked to the description.
These measures are needed for people using non-graphical browsers.

For further advice on how to make your pages accessible
see http://www.w3.org/WAI/GL.
. You may also want to try
"http://www.cast.org/bobby/" which is a free Web-based
service for checking URLs for accessibility.

To learn more about HTML Tidy see http://tidy.sourceforge.net
Please fill bug reports and queries using the "tracker" on the Tidy web site.
Additionally, questions can be sent to html-tidy@w3.org
HTML and CSS specifications are available from http://www.w3.org/
Lobby your company to join W3C, see http://www.w3.org/Consortium

@geoffmcl
Copy link
Contributor

@sjeeva thank you for your issue...

First, what version of tidy are you using? That sourceforge reference suggests a version back at 2009, or before!, nearly 10 years ago! Current tidy source is at https://github.com/htacg/tidy-html5, and the current master branch version is 5.6.0, the next version is 5.7.3

And you do not show the input that caused the error and/or warning messages...

You seem to be asking two questions -

  1. How to disable an error message - document has errors that must be fixed ...
  2. How to disable the info message - To learn more about HTML Tidy see http://tidy.sourceforge.net...

As to the first question you can not disable error messages. In current tidy, you can use --force-output yes to push tidy to do an output even if there are errors, and you can use --show-info no or --quiet, -q to suppress most info type messages...

But please show the tidy version, run tidy -v, and give a minimal sample html input, configuration used, current output, and expected output to clearly show what you are talking about, asking... thanks...

@geoffmcl geoffmcl added this to the 5.7 milestone Mar 15, 2018
@balthisar
Copy link
Member

Due to lack of feedback, I'm closing this. Please feel free to re-open if new information comes in.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants