[Question] Generating two copies of API documentation with differing filters with single build
- Dominant language
- C#
- Stars
- 4.4k
- Forks
- 890
- Avg merge
- 2h 11m
- Merged PRs (30d)
- 10
Description
Hello,
I'm running DocFX 2.56.2. I have a C# project, and am attempting to generate two copies of the API documentation with a single build. The first copy is documenting the public API with the default filter, while the second copy documents the internal codebase with a custom filter to reach private classes and methods. I have yet to modify the Codebase part of the `doxfx.json` to reflect the required filters, but I am having issues before reaching that step.
It would appear there is conflict within the build part of the generation, as after attempting to generate the documentation I am getting hundreds of errors along the lines of:
`Warning:[BuildCommand.BuildCore.Build Document.LinkPhaseHandlerWithIncremental.ManagedReferenceDocumentProcessor.Save](Codebase/MYCLASSMETHOD.yml)Uid(MYCLASSMETHOD) has already been defined in API/MYCLASSMETHOD.yml.`
Is there a way of doing this without having two separate docfx files?
Thank you.
doxfx.json:
```
{
"metadata": [
{
"src": [
{
"src":"../src/",
"files": [
"**.csproj"
],
"exclude":[
"**/bin/**",
"**/obj/**",
"_site/**"
]
}
],
"dest": "API",
"disableGitFeatures": true,
"disableDefaultFilter": false
},
{
"src": [
{
"src":"../src/",
"files": [
"**.csproj"
],
"exclude":[
"**/bin/**",
"**/obj/**",
"_site/**"
]
}
],
"dest": "Codebase",
"disableGitFeatures": true,
"disableDefaultFilter": false
}
],
"build": {
"content": [
{
"files": [
"API/**.yml",
"API/index.md"
]
},
{
"files": [
"Library Documentation/**.md",
"Library Documentation/**/toc.yml",
"toc.yml",
"*.md"
]
},
{
"files": [
"Codebase/**.yml",
"Codebase/index.md"
]
}
],
"resource": [
{
"files": [
"images/**"
]
}
],
"overwrite": [
{
"files": [
"apidoc/**.md"
],
"exclude": [
"obj/**",
"_site/**"
]
}
],
"dest": "_site",
"globalMetadataFiles": [],
"fileMetadataFiles": [],
"template": [
"default"
],
"postProcessors": [],
"markdownEngineName": "markdig",
"noLangKeyword": false,
"keepFileLink": false,
"cleanupCacheHistory": false,
"disableGitFeatures": true
}
}
```
toc.yml:
```
- name: Library Documentation
href: Library Documentation/
- name: Api Documentation
href: api/
- name: Codebase
href: Codebase/
homepage: api/index.md
```
Contributor guide
Assessment
This issue has not been assessed yet.