XUPDATE(1p)
β¨ XUPDATE(1p) β like, the whole vibe β¨
okay bestie, sit DOWN, because we're talking about xupdate, a lil program from the User Contributed Perl Documentation corner of the universe π. It's giving "I process XUpdate commands over an XML document" and honestly? iconic.
πΈ NAME πΈ
xupdate β Process XUpdate commands over an XML document π¦
π SYNOPSIS π
xupdate [options] <xupdate-file> <input-file>
Options:
-u | --usage print brief help on usage
-h | --help print documentation
-n | --namespace prefix=namespace-uri
associate a namespace with a prefix for use
in XPath selections in XUpdate file
(this option may occur several times)
-k | --keep-ws preserve whitespace in the XUpdate file
-s | --strip-ws strip ignorable whitespace from the input file
-V | --version print current version and revision
-i | --indent indent the output XML
-j | --extra-indent like -i, but also adds a leading and a trailing
linebreak to every text node.
but also put an extra newline after
every start-tag and before every end-tag
so yeah, you hand it an xupdate-file and an input-file and it does the thing β¨ no cap.
π OPTIONS π
--usageβ Prints a lil brief help message on usage and then dips out. short and sweet, we love that for her π--helpβ Prints the manual page and exits. the full lore, basically π--namespace prefix=namespace-uriβ Associates a namespace with a prefix, bestie. That prefix can then be used in the XPath selections inside the XUpdate file to address nodes of the source document that belong to that namespace. This is especially useful for mapping the default namespace to a prefix, because XPath by definition does not honour default namespaces π (rude of it, honestly). You can use this option several times β stack 'em up, periodt π--keep-wsβ Preserves any whitespace in the XUpdate file. The default behaviour is to remove all ignorable whitespace and any leading or trailing whitespace in all XUpdate command elements in the XUpdate file. so if you want your whitespace kept, you gotta say so π«Ά--strip-wsβ Remove "ignorable" whitespace from the input file. The default behaviour is to keep any whitespace unless the--extra-indent(-j) option is used. Heads up though: whether that whitespace is present or not can affect results returned by some XPath expressions (like/foo/bar/text()[2]) π³ so choose wisely--versionβ Print the version and revision number of This program command and the version number of theXML::XUpdatelibrary used. receipts, but for software π§Ύ--indentβ Indent the resulting document on output. pretty output supremacy β¨--extra-indentβ Indent the resulting document on output just like--indent, but also add a leading and a trailing linebreak to every text node. extra. we stan π--debugβ Print some debugging information about commands being applied. for when you're nosy (affectionate) π
π¦ DESCRIPTION π¦
This program will parse the given XUpdate file and the input file, and print the input file updated accordingly. That's the whole gig, and she does it well π
The XUpdate file format is described in the XUpdate Working Draft from 2000-09-14 β yes, the URL is literally http://www.xmldb.org/xupdate/xupdate-wd.html, go look, iykyk π₯
β AUTHOR β
Petr Pajas, pajas@matfyz.cz β the main character who made all this happen π
π COPYRIGHT π
Copyright 2002-2003 Petr Pajas, All rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. free as in, go off, do your thing π
okay that's the whole page bestie, you're officially educated πβ¨
sign-off time: this lil gem is from perl v5.32.0, dated 2021-01-07, and it lives under the manual name XUPDATE(1p) ππ
π¦
π¦ where this page comes from
- debian bookworm: libxml-xupdate-libxml-perl 0.6.0-3.1
- debian trixie: libxml-xupdate-libxml-perl 0.6.0-3.1
- ubuntu jammy: libxml-xupdate-libxml-perl 0.6.0-3.1
- ubuntu noble: libxml-xupdate-libxml-perl 0.6.0-3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms