dotnet / dotnet/machinelearning
Simplify include repo configuration in ml-api-docs repo
- Dominant language
- C#
- Stars
- 9.4k
- Forks
- 2k
- Avg merge
- 2d 20h
- Merged PRs (30d)
- 11
Description
The current config in https://github.com/dotnet/ml-api-docs is:
.openpublishing.publish.config.json
"dependent_repositories": [
...
{
"path_to_root": "docs/samples",
"url": "https://github.com/dotnet/machinelearning",
"branch": "master",
"branch_mapping": {}
}
],
This means that the includes have to be specified like this:
[!code-csharp[OrdinaryLeastSquares](~/../docs/samples/docs/samples/Microsoft.ML.Samples/Dynamic/Trainers/Regression/OrdinaryLeastSquares.cs)]
and
[!include[algorithm](~/../docs/samples/docs/api-reference/tree-featurization-prediction.md)]
If we change it to
.openpublishing.publish.config.json
{
"path_to_root": "dotnet/machinelearning", <-- ~ is relative to the docfx root dir i.e. dotnet
"url": "https://github.com/dotnet/machinelearning",
"branch": "master",
"branch_mapping": {}
}
then we can specify the includes as:
[!code-csharp[OrdinaryLeastSquares](~/machinelearning/docs/samples/Microsoft.ML.Samples/Dynamic/Trainers/Regression/OrdinaryLeastSquares.cs)]
[!include[algorithm](~/machinelearning/docs/api-reference/tree-featurization-prediction.md)]
Contributor guide
Assessment
This issue has not been assessed yet.