How to validate HTML and other quality testing with jekyll?

I occassionally test the validity of my site’s HTML using

I do this manually in a browser and fix whatever problems there may be.

I currently use a Makefile to build my jekyll sites.
In this Makefile I also have tests that run some link checking, etc. to make sure I have no broken links.

Is there a way I can put in automatic validation of my HTML directly from such Makefile?
That is, it needs to test my local non-published site. Preferably completely offline using a CLI tool…

Additionally, I would love to hear what checks and tests you do on your jekyll build scripts.

Is anyone else using Makefiles? If so, I would love to see examples of your Makefiles as I am not really good at making those myself.

Back in my Jekyll days I use to use HTML Proofer:

It doesn’t catch everything, but the stuff that matters :+1:

1 Like

Thanks for pitching in!

I have been using htmlproofer for quite a while to check for broken links. It does have some html validator, but I am not sure it actually works. At least it says my site have no issues but when running it through it finds several issues…

1 Like

This is what I used to use fairly frequently: