build.ps1 495 B

12345678910111213141516171819202122
  1. # Builds the Terminal.gui API documentation using docfx
  2. $prevPwd = $PWD; Set-Location -ErrorAction Stop -LiteralPath $PSScriptRoot
  3. try {
  4. $PWD # output the current location
  5. dotnet tool update -g docfx
  6. dotnet build --configuration Release ../Terminal.sln
  7. rm ../docs -Recurse -Force -ErrorAction SilentlyContinue
  8. $env:DOCFX_SOURCE_BRANCH_NAME="v2_develop"
  9. docfx --metadata --serve --force
  10. }
  11. finally {
  12. # Restore the previous location.
  13. $prevPwd | Set-Location
  14. }