dctrl2xml(1)
β¨ dctrl2xml β the Debian control data to XML glow-up β¨
okay bestie, so this is the manual page for dctrl2xml(1) π and honestly? it's giving "tiny tool, huge main character energy." it takes boring Debian control data and turns it into XML (or JSON, we'll get there π¦). no cap.
πΈ SYNOPSIS πΈ
dctrl2xml [-x | -j] [-f FILE]
that's it. that's the whole vibe. three little flags and she's done π
π DESCRIPTION π
so dctrl2xml is a tool that converts Debian control data into an XML representation. literally what it says on the tin, no notes. π
you can point it at the kind of data that normally lives in debian/control, .changes, .dsc, Packages, Sources, and similar files, and it will hand you back XML. it's that girl.
here's the tea tho β for most fields, dctrl2xml just uses the field name as the element name and the field data as the element content. simple. clean. iconic. but for other fields β think package interrelationship fields like Depends, Build-Depends, etc., or the Files field in .changes or Sources files β dctrl2xml additionally parses their field data to represent it in a more fine-structured form. she does the extra work so you don't have to π₯
β¨ OPTIONS β¨
for a full summary of options, run dctrl2xml --help. but here's the rundown, bestie:
--versionβ showsdctrl2xml's version number. quick little "who am i" moment π«-h,--helpβ shows help about options. your girl is here to help fr fr π«Ά-f FILE,--file=FILEβ reads Debian control data from file FILE instead of standard input. and FILE can be either a plain text file or agzip,bzip2orZIPfile. yes she handles compressed files, she's versatile like that π-x,--xmlβ outputs Debian control data as XML (default). the classic. the original flavor. π-j,--jsonβ outputs Debian control data as JSON. for when you're feeling a little different today π¦
π EXAMPLES π
okay these are so fun, watch this:
dctrl2xml -f /var/lib/dpkg/availableβ converts the wholedpkg(1)available file to XML and prints it to standard output. this is a typical stress test fordctrl2xml. like, she's out here doing cardio πβοΈπ¨apt-cache show hello build-essential | dctrl2xmlβ converts the package records of thehelloandbuild-essentialpackages to XML and prints it to standard output. this is an example of howdctrl2xmlcan be used in pipes where it reads the control data from standard input. pipe girlie behavior πapt-cache showsrc hello | dctrl2xml | xmllint --format -β similar to the above example, except that thexmllint(1)tool (which is in thelibxml2-utilsDebian package) is used to reformat and reindentdctrl2xml's output to make it more human readable, and that the source package records of thehellopackage are used. glow-up pipeline β¨apt-cache showsrc hello | dctrl2xml -jβ in this examplehello's source package record is printed as JSON instead of XML. switching teams, respect π
π SEE ALSO π
deb-control(5)β go read it, bestie, it's the lore π
π AUTHOR π
written by Frank S. Thomas <fst@debian.org>. king behavior honestly π
and that's the whole page, babe π go convert something. you got this.
this manual page is dctrl2xml(1), dated 20 August 2010 β yeah she's a vintage icon and she still slays πβ¨
π¦ where this page comes from
- debian trixie: dctrl2xml 0.24
- ubuntu questing: dctrl2xml 0.24
- ubuntu resolute: dctrl2xml 0.24build1
- ubuntu stonking: dctrl2xml 0.24build1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms