dub --build=docs takes all of the modules in the project and generates the corresponding .html files but does not retain the package hierarchy. You just get a bunch of .html files in the same folder with the file names matching the corresponding source files. That's not particularly ideal under any circumstances, but it's a huge problem if there are modules with the same name in different packages, and it does not lend itself to having ddoc macros for generating links between symbols in the project. Is there any way to get dub to put them in folders that match the actual source code? Barring that, is there a way to make the file names contain the source hierarchy but with underscores in their names to replace the slashes (like Phobos does)?
It looks like this is partly dmd's fault, because it just uses the module names for the file names, but I would expect that dub could be made to do the documentation build in a way that properly retains the package hierarchy. Is there any way to do that now, or would it require improvements to dub? Right now, it's looking like I won't be able to use dub to build documentation for my projects if I want to retain the package hierarchy.