dpkg-scansources(1)
πΈ dpkg-scansources β bestie edition β¨
okay so this is the dpkg-scansources(1) page from the dpkg suite, and it is literally the tool that builds your Sources index files π
buckle up.
β¨ NAME β¨
dpkg-scansources β the girl that creates Sources index files π
π¦ SYNOPSIS π¦
dpkg-scansources [option...] binary-dir [override-file [path-prefix]] > Sources
that's it. that's the whole vibe check. redirect it into Sources and you're serving π
π DESCRIPTION π
okay so dpkg-scansources goes rummaging through the binary-dir you gave it, hunting for .dsc files π΅οΈββοΈ those bad boys get used to build a Debian source index, and that index gets dumped to stdout. iconic.
the override-file, if you give one, does two jobs: it sets priorities in the resulting index stanzas, and it overrides the maintainer field that's sitting in the .dsc files. and yes, the file can be compressed (since dpkg 1.15.5) β we love a flexible queen π«Ά peep deb-override(5) for the format of this file.
β οΈ note, bestie: the override file is indexed by binary, not source packages, so there's a bit of a problem here. the current implementation uses the highest priority of all the binary packages produced by a.dscfile for the priority of the source package, and it uses the override entry for the first binary package listed in the.dscfile to modify maintainer information. this might change. so likeβ¦ don't build your whole personality on it π
the path-prefix, if given, gets prepended to the directory field in the generated source index. you generally use this to make the directory fields contain the path from the top of the Debian archive hierarchy. very "know your roots" of you π
β οΈ another note: if you want to access the generatedSourcesfile withapt(8)you will probably need to compress the file withgzip(1)(generating aSources.gzfile).apt(8)ignores uncompressedSourcesfiles except on local access (i.e.file://sources). no cap, it will simply not see them π
π OPTIONS π
-n,--no-sortβ do not sort the index stanzas. normally they're sorted by source package name. choose chaos π-e,--extra-overridefile β scan file to find supplementary overrides. the file can be compressed (since dpkg 1.15.5). seedeb-extra-override(5)for more info on its format. supported since dpkg 1.15.4 π-s,--source-overridefile β use file as the source override file. the file can be compressed (since dpkg 1.15.5). the default is the name of the override file you specified with.srcappended. the source override file is in a different format from the binary override file β it contains only two whitespace-separated fields, the first is the source package name and the second is the section. blank lines and comment lines are ignored in the normal manner. if a package appears in both files, the source override takes precedence for setting the section. she said "i'll handle it" and she did π--debugβ turn debugging on. give the people (and the logs) what they want π₯--helpβ show the usage message and exit. the classic escape hatch π--versionβ show the version and exit. hi bestie, what's your sign (it's a number) β
πΈ ENVIRONMENT πΈ
DPKG_COLORSβ sets the color mode. the currently accepted values are:auto(default),alwaysandnever. supported since dpkg 1.18.5. yes you can force the pretty πDPKG_NLSβ if set, it will be used to decide whether to activate Native Language Support, also known as internationalization (or i18n) support. the accepted values are:0and1(default). supported since dpkg 1.19.0. translating the manual is main character energy π§
π SEE ALSO π
deb-override(5), deb-extra-override(5), dpkg-scanpackages(1). read them, love them, link them in the group chat π
and that's the whole page, bestie π«Ά this was dpkg-scansources(1) from the dpkg suite, version 1.23.11-dirty, dated 2026-09-09. go make some gorgeous Sources.gz files, slay, and remember: sort your stanzas unless you're feeling feral π
β¨
π¦ where this page comes from
- arch rolling: dpkg 1.23.11-1 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms