(#112, #114) Save search metadata as a separate document. #183
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build Web App | |
on: | |
## This tries to avoid unessesary pushes to forked repo | |
## development branches. No sense in a dev building every | |
## time they push for a PR and no one should be working on | |
## common branches in their fork. | |
push: | |
branches: | |
- main | |
- master | |
- develop | |
- 'hotfix/**' | |
- 'release/**' | |
- 'feature/**' | |
pull_request: | |
jobs: | |
test_build_release: | |
name: Test, Build, and Publish | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v4 | |
name: Checkout Code | |
- name: Setup MSBuild Path | |
uses: microsoft/setup-msbuild@v2 | |
with: | |
# Stick to VS 2022, block later versions for now. | |
vs-version: '[17.0,18.0)' | |
- name: Setup NuGet | |
uses: NuGet/setup-nuget@v2 | |
- name: Restore NuGet Packages | |
run: nuget restore clinical-trials-search-print.sln | |
- name: Build | |
run: | | |
REM Find and build all the unit test projects. | |
for /r test %%a in (*.csproj) do ( | |
msbuild %%a /p:TreatWarningsAsErrors=true /p:Configuration=Release | |
) | |
shell: cmd | |
- name: Run Unit Tests | |
run: msbuild test\RunUnitTests.targets /p:Configuration=Release | |
- name: Publish | |
run: | | |
msbuild clinical-trials-search-print.sln /p:TreatWarningsAsErrors=true /p:Configuration=Release /p:DeployOnBuild=true /p:PublishProfile=FolderProfile | |
copy tools\deploy-site.ps1 publish\*.* | |
shell: cmd | |
- name: Record metadata | |
uses: nciocpl/[email protected] | |
with: | |
output-name: "${{github.workspace}}/publish/cts.print/build-info.json" | |
- name: Upload Artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: clinical-trials-search-print | |
path: .\publish | |