Skip to content

Commit

Permalink
fix: Support generation of stable vs unstable
Browse files Browse the repository at this point in the history
  • Loading branch information
Kieranties committed May 28, 2020
1 parent 9e47bd7 commit 5cfa27b
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ coverage.json
**/site/api/*.yml
**/site/api/.manifest
**/site/manifest.json
**/site/schema/latest.json
**/site/schema/
2 changes: 1 addition & 1 deletion .simpleversion.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"$schema": "http://localhost:8080/schema/latest.json",
"$schema": "http://simpleversion.kieranties.com/schema/unstable.json",
"version": "0.4.0",
"branches": {
"release": [".+"],
Expand Down
2 changes: 1 addition & 1 deletion src/SimpleVersion.Docs/Properties/launchSettings.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"profiles": {
"SimpleVersion.Docs": {
"commandName": "Project",
"commandLineArgs": "$(MSBuildThisFileDirectory)site/schema/latest.json"
"commandLineArgs": "$(MSBuildThisFileDirectory)site/schema/local.json"
}
}
}
7 changes: 6 additions & 1 deletion src/SimpleVersion.Docs/SimpleVersion.Docs.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,12 @@

<Target Name="GenerateSchema" AfterTargets="Build">
<!-- Generate the schema and add to site assets -->
<Exec Command="dotnet $(OutputPath)/$(AssemblyName).dll $(MSBuildThisFileDirectory)site/schema/latest.json" />
<PropertyGroup>
<FileName>latest</FileName>
<FileName Condition="$(Version.Contains('-'))">unstable</FileName>
</PropertyGroup>

<Exec Command="dotnet $(OutputPath)/$(AssemblyName).dll $(MSBuildThisFileDirectory)site/schema/$(FileName).json" />
</Target>

<Target Name="DocFxBuild" AfterTargets="Publish">
Expand Down

0 comments on commit 5cfa27b

Please sign in to comment.