Code Yarns ‍👨‍💻
Tech BlogPersonal Blog

How to build and install HTML Tidy

📅 2016-Jun-06 ⬩ ✍️ Ashwin Nanjappa ⬩ 📚 Archive

HTML Tidy is an old and classic program that can be used to fix errors and correct indentation of a HTML file.

It can be installed easily in Ubuntu:

$ sudo apt install tidy

However, the version from Ubuntu is extremely old and does not support HTML5. It is pretty pointless to install and use this ancient version today.

To download and build the latest HTML Tidy, try these commands:

$ git clone https://github.com/htacg/tidy-html5.git
$ cd tidy-html5
$ cd build/cmake
$ cmake ../..
$ cmake --build . --config Release

To install it:

$ sudo make install

Tried with: HTML Tidy 5.2.0 and Ubuntu 14.04