Skip to content

Commit

Permalink
Merge pull request #72 from fluentmigrator/feature/issue-71-fix-docfx…
Browse files Browse the repository at this point in the history
…-build

Fix issue #71 - docfx build
  • Loading branch information
eloekset committed Feb 17, 2024
2 parents 2303493 + 4488a13 commit 478123c
Show file tree
Hide file tree
Showing 4 changed files with 61 additions and 24 deletions.
14 changes: 7 additions & 7 deletions api/toc.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
- name: Version 2.x
href: v2.x/toc.yml
topicHref: v2.x/index.md
topicHref: v2.x/index.html
- name: Version 3.x
href: v3.x/
topicHref: v3.x/index.md
href: v3.x/toc.yml
topicHref: v3.x/index.html
- name: Version 4.x
href: v4.x/
topicHref: v4.x/index.md
href: v4.x/toc.yml
topicHref: v4.x/index.html
- name: Version 5.x
href: v5.x/
topicHref: v5.x/index.md
href: v5.x/toc.yml
topicHref: v5.x/index.html
19 changes: 5 additions & 14 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,27 +9,18 @@ trigger:
pool:
vmImage: 'ubuntu-latest'

variables:
docFxTool: 'mono docfx.console/tools/docfx.exe'

steps:
- script: |
git submodule update --init --recursive
displayName: 'Update submodules (main fluentmigrator repo)'

- task: NuGetToolInstaller@1

# We need to use 2.59.4 of docfx.console due to https://github.com/dotnet/docfx/issues/8097
# which is fixed by https://github.com/dotnet/docfx/pull/8135
- task: NuGetCommand@2
displayName: 'Install docfx.console'
inputs:
command: 'custom'
arguments: 'install docfx.console -Version 2.59.4 -ExcludeVersion'
- script: |
dotnet tool install -g docfx --version 2.75.2
displayName: 'Install dotnet tool DocFX'

- script: |
$(docFxTool) metadata docfx.json
$(docFxTool) build docfx.json
docfx metadata docfx.json
docfx build docfx.json
displayName: 'Run DocFX build'

- task: ArchiveFiles@2
Expand Down
47 changes: 44 additions & 3 deletions docfx.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"filter": "api-filter.yml",
"disableGitFeatures": true,
"properties": {
"TargetFramework": "net461"
"TargetFramework": "net45"
}
},
{
Expand Down Expand Up @@ -81,7 +81,7 @@
"filter": "api-filter.yml",
"disableGitFeatures": true,
"properties": {
"TargetFramework": "net461"
"TargetFramework": "net48"
}
}
],
Expand All @@ -96,7 +96,20 @@
{
"files": [ "**.yml", "**.md" ],
"src": "api/v3.x",
"dest": "api/v3.x"
"dest": "api/v3.x",
"group": "v3.x"
},
{
"files": [ "**.yml", "**.md" ],
"src": "api/v4.x",
"dest": "api/v4.x",
"group": "v4.x"
},
{
"files": [ "**.yml", "**.md" ],
"src": "api/v5.x",
"dest": "api/v5.x",
"group": "v5.x"
},
{
"files": [
Expand Down Expand Up @@ -139,6 +152,24 @@
"obj/**",
"_site/**"
]
},
{
"files": [
"apidoc/v4.x/**.md"
],
"exclude": [
"obj/**",
"_site/**"
]
},
{
"files": [
"apidoc/v5.x/**.md"
],
"exclude": [
"obj/**",
"_site/**"
]
}
],
"dest": "_site",
Expand Down Expand Up @@ -177,6 +208,16 @@
"repo": "https://github.com/fluentmigrator/documentation",
"branch": "master",
"apiSpecFolder": "apidoc/v3.x"
},
"api/v4.x/**": {
"repo": "https://github.com/fluentmigrator/documentation",
"branch": "master",
"apiSpecFolder": "apidoc/v4.x"
},
"api/v5.x/**": {
"repo": "https://github.com/fluentmigrator/documentation",
"branch": "master",
"apiSpecFolder": "apidoc/v5.x"
}
}
}
Expand Down
5 changes: 5 additions & 0 deletions global.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"sdk": {
"version": "8.0.101"
}
}

0 comments on commit 478123c

Please sign in to comment.