HXPRUNE(1)

✨ hxprune β€” the HTML-XML-utils glow-up πŸ’…

okay bestie, welcome to hxprune(1), part of the HTML-XML-utils fam 🫢


🌸 NAME 🌸

hxprune β€” literally just: remove marked elements from an HTML file 🧹✨


πŸ¦‹ SYNOPSIS πŸ¦‹

hxprune [ -c class ] [ -x ] [ file ]

πŸ’– DESCRIPTION πŸ’–

so here's the tea, bestie πŸ“ hxprune removes specially marked elements from an HTML file β€” and when I say removes, I mean the element, its content, AND all its children, gone, no trace, not me ghosting them πŸ’€

by default it goes after elements that have a class attribute of "exclude". and the way it figures that out? the class attribute gets parsed as a whitespace-separated list of words, and if one of those words is "exclude", that element does NOT get copied to the output. periodt. πŸ‘‘


πŸ‘‘ OPTIONS πŸ‘‘

the following options are supported, and yes we're listing all of them, there are exactly two, iconic:

  • -c class β€” specify a different class than "exclude". want to prune something else? say less πŸ’…
  • -x β€” force the output to be in XML-style. that means no short attributes, and empty elements get marked with a slash (/). very demure, very XML 🌈

ngl bestie, if you don't pass a file, it's giving "reads from standard input" energy. and those flags? copy them exactly as written, no improvising πŸŽ€

πŸ’œ SEE ALSO πŸ’œ

wait, there's nothing here in the original... okay so just go read the rest of the HTML-XML-utils manpages yourself, iykyk 😭


and that's a wrap, my love πŸ’– this was hxprune from the HTML-XML-utils, version 7.x, dated 10 Jul 2011 β€” old but gold, fr fr βœ¨πŸŽ€πŸ¦‹πŸŒΈπŸ’…πŸ«Ά