SDML(1)
okay so bestie π you just opened SDML(1) β that's section 1 of the User Commands manual β and this whole page is about sdml deps, aka the subcommand that spills the entire tea on what a module imports. no cap, it's giving detective energy π΅οΈβοΈβ¨
π NAME π
sdml deps β Show a module's imported dependencies. that's it, that's the whole assignment π
π SYNOPSIS π
sdml deps [OPTIONS] [MODULE]
π DESCRIPTION π
okay so, sdml deps shows a module's imported dependencies π
what it's actually doing: it generates a representation of the transitive closure of dependencies for a given module. like, not just your module's bestie β everybody downstream too, fr fr π₯
you get three flavours:
- Tree (the default, obviously β¨) β shows the dependencies as a text tree, with the original module as the root, main character energy only.
$ sdml deps sdml
sdml
????????? owl ??? ????????? rdf ??? ??? ????????? rdfs ??? ??? ????????? rdf ??? ????????? rdfs ??? ????????? xsd ??? ????????? rdf ??? ????????? rdfs ????????? rdf ????????? rdfs ????????? skos ??? ????????? rdf ??? ????????? rdfs ????????? xsd
ngl, the box-drawing glyphs in that example got their whole life eaten by an encoding situation in the source page π every module name is still in there though βowl,rdf,rdfs,skos,xsdβ so you can absolutely clock the shape: your module at the root, its imports branching out underneath.
- Graph β creates an SVG representation of the dependency graph using GraphViz π¨
$ sdml deps --output-format graph -o sdml-deps.svg sdml
$ open -a Safari sdml-deps.svg
- RDF β creates a set of RDF statements, as N-Triples, that represent the individual OWL import relationships π¦
$ sdml deps --depth 1 --output-format rdf sdml
<http://sdml.io/sdml-owl.ttl#> <http://www.w3.org/2002/07/owl#imports> <http://www.w3.org/2002/07/owl#> .
<http://sdml.io/sdml-owl.ttl#> <http://www.w3.org/2002/07/owl#imports> <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
<http://sdml.io/sdml-owl.ttl#> <http://www.w3.org/2002/07/owl#imports> <http://www.w3.org/2000/01/rdf-schema#> .
<http://sdml.io/sdml-owl.ttl#> <http://www.w3.org/2002/07/owl#imports> <http://www.w3.org/2004/02/skos/core#> .
<http://sdml.io/sdml-owl.ttl#> <http://www.w3.org/2002/07/owl#imports> <http://www.w3.org/2001/XMLSchema#> .
and sometimes you truly do not need the entire set, and that's so valid π β in that case you can add the --depth argument to only show a number of levels of import from the root. the depth argument tells the command to stop after that many dependencies away from the original module. setting depth to 1 will only show the direct dependencies of the original. iconic behaviour, honestly.
$ sdml deps --depth 1 sdml
sdml
????????? owl
????????? rdf
????????? rdfs
????????? skos
????????? xsd
(same deal as above β those ????????? are the tree-drawing chars that did not survive the encoding π the five direct imports are all right there though.)
πΈ Arguments πΈ
[MODULE]β an SDML module, loaded using the standard resolver. yes bestie, the normal one, no special tricks π«Ά
β¨ OPTIONS β¨
-f,--output-format <OUTPUT_FORMAT>β pick your format, bestie. possible values:graph: GraphViz DOT formatrdf: As RDF/OWL import triplestree: A hierarchical tree format
[default: tree] β because tree is the moment π
-d,--depth <DEPTH>β depth to traverse imports,0implies all of them. [default:0]-o,--output <OUTPUT>β file name to write to, or-to write to stdout. [default:-]-i,--input <INPUT>β input SDML file name to read from, or-to read from stdin. [default:-]-h,--helpβ Print help (see a summary with-h). the shorter-hgives you the quick version, iykyk π-V,--versionβ Print version. gotta know what you're running, periodt π₯
that's the whole page, bestie, and you ate it π«Ά this was sdml deps version 0.3.2+20250310, dated October 2025, living its best life as page SDML(1) in the User Commands manual. go forth and map some dependencies ππβ¨
π¦ where this page comes from
- ubuntu resolute: sdml 0.3.2+20250310-5 Β· Apache-2.0
- ubuntu stonking: sdml 0.3.2+20250310-5 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms