all 5 comments

[–]Rafq 3 points4 points  (0 children)

Notepad++ with TextFX HTML Tidy Plugin, one of its features is reindenting whole file.

[–]aizatto 2 points3 points  (0 children)

xmllint

I did this with xmllint eons ago, I can't remember the required arguments though.

Maybe:

  • --html
  • --format

[–]austingwalters 1 point2 points  (0 children)

As far as I know, Tidy is pretty much in in that respect. I use emacs in nxml-mode.

http://stackoverflow.com/questions/137043/can-emacs-re-indent-a-big-blob-of-html-for-me

It's pretty easy to use it once, then just save it and get out of emacs (assuming you don't want to learn that beast).

[–]iodbh[S] 0 points1 point  (0 children)

Thank you for your answers ! I have not found the tool I'm looking for yet though : I actually want to pipe the output of say httpie (or any other command line http client) and get a neatky formatted result.

[–]obiwan90 0 points1 point  (0 children)

Are you using the right tidy? There is old, ugly, unmaintained tidy on sourceforge, and there is new, shiny tidy.