Tidy-html5 on Mac OS: how to install
Asked Answered
T

6

17

Please help

I need to install HTML tidy on Mac OS http://w3c.github.com/tidy-html5/

I call the commands in the Terminal and get nothing:

$ make -C build/gmake/
make: *** build/gmake/: No such file or directory. Β Stop.

$ sh build/gnuauto/setup.sh && ./configure && make
sh: build/gnuauto/setup.sh: No such file or directory

What's the problem? What else should I install?

Toddtoddie answered 14/11, 2012 at 13:45 Comment(0)
C
27

The following worked for me:

brew update
brew install tidy-html5

Shell output:

➜  ~  brew install tidy-html5
==> Downloading https://homebrew.bintray.com/bottles/tidy-html5-4.9.26.yosemite.
######################################################################## 100.0%
==> Pouring tidy-html5-4.9.26.yosemite.bottle.tar.gz
🍺  /usr/local/Cellar/tidy-html5/4.9.26: 8 files, 1.2M
Certainty answered 12/6, 2015 at 8:1 Comment(2)
This is now the correct answer, the others are obsolete. – Detta
Thanks for bringing it up! @Vladimir, kindly mark the answer correct if this worked for you! – Certainty
S
15

tidy-html5 has been promoted to stable, so you should simply need to run in an up-to-date installation of Homebrew the command:

$ brew install tidy-html5
Stilbite answered 4/12, 2013 at 2:0 Comment(3)
If tidy is already installed don't forget to first run "brew unlink tidy" – Amalgam
Installing with --HEAD worked for me. The only caveat being tidy ends up at /usr/local/bin/tidy5. Thanks @PedroRomano. – Brumbaugh
tidy-html5 has been promoted to stable so the answer has been updated accordingly. – Stilbite
T
5

It didn't work for me, but here is what did:

Tap dupes repository:

brew tap homebrew/dupes

Homebrew dupes repository contains

formulae [that] duplicate software provided by OS X, though may provide more recent or bugfix versions.

Then install from the dupes repository:

brew install tidy --HEAD
Timeserver answered 19/5, 2014 at 19:15 Comment(3)
try brew install tidyp – Comestible
This answer is the correct solution, not sure why it was down voted. – Grosz
"tidyp does not validate HTML 5." – Grosz
A
2

To install tidy5 which is the most up-to-date version of Tidy for OS X:

Ensure you have homebrew installed.

Then tap the dupes repository which provides brew recipes for new versions / bug fixes of software which is provided by the OS X system.

$ brew tap homebrew/dupes

Install Tidy (tidy-html5)

$ brew install --HEAD tidy

Untap the dupes repository

$ brew untap homebrew/dupes

To invoke

$ tidy5 -v  
> HTML Tidy for Mac OS X version 5.4.0
Aroid answered 17/3, 2015 at 11:10 Comment(1)
When I run $ brew install --HEAD tidy the install reaches the ==> make install step, but then breaks on the following error: Error: parent directory is world writable but not sticky – any ideas? I'm not even sure which directory it's referring to. – Leyes
L
1

I've just installed the Tidy in Mac OS X 10.9.1:

brew install tidy

It will automatically install its dependencies: automake and libtool

And you may notice, I have a default tidy under /usr/bin/tidy, which has a version:

HTML Tidy for Mac OS X released on 31 October 2006 - Apple Inc. build 15.12

After installation of Homebrew, the version appears as

HTML Tidy for Mac OS X released on 25 March 2009

, under the path: /usr/local/Cellar/20090325/bin/tidy

Loaiasis answered 9/2, 2014 at 5:50 Comment(1)
Oh shoot, I forgot to update my $PATH so it was picking /usr/bin/tidy instead of /usr/local/Cellar/tidy-html5/5.4.0/bin/tidy – Delois
E
0

The problem is that the documentation doesn't mention that you have to be in the bundle directory to run the first commands. The commands given are relative to the bundle directory.

Steps I just did successfully yesterday:

cd ~/Library/Application Support/Avian/Pristine Copy/Bundles git clone https://github.com/w3c/tidy-html5 cd tidy-html5/ sudo make -C build/gmake/ sudo make install -C build/gmake/

Not sure about the shared library part because I did not go through those steps.

Erda answered 17/10, 2014 at 14:48 Comment(0)

© 2022 - 2024 β€” McMap. All rights reserved.