-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
61 additions
and
1 deletion.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
name: CI pipeline | ||
# This workflow is triggered on pushes to the repository. | ||
on: | ||
push: | ||
tags: | ||
- 3.[0-9]+.[0-9]+-alpha.[0-9]+ | ||
jobs: | ||
build: | ||
name: Test & Coverage | ||
runs-on: windows-latest | ||
env: | ||
FS_API_KEY: "${{ secrets.FS_CI_CAMPAIGNS_API_KEY }}" | ||
FS_ENV_ID: "${{ secrets.FS_CI_CAMPAIGNS_ENV_ID }}" | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-dotnet@v1 | ||
with: | ||
dotnet-version: "6.0.x" | ||
|
||
- name: Setup NuGet | ||
uses: NuGet/setup-nuget@v1 | ||
env: | ||
ACTIONS_ALLOW_UNSECURE_COMMANDS: "true" | ||
|
||
- name: Restore NuGet Packages | ||
run: nuget restore Flagship.sln | ||
|
||
- name: Add msbuild to PATH | ||
uses: microsoft/setup-msbuild@v1.0.2 | ||
|
||
- name: Build dll | ||
run: MSBuild Flagship.Tests/Flagship.Tests.csproj -property:Configuration=Debug | ||
|
||
- name: Run tests | ||
shell: pwsh | ||
run: ./coverage-ci.bat | ||
|
||
- name: Create signing Key file | ||
shell: pwsh | ||
run: ${{ secrets.ASSEMBLY_SIGNING_KEY }} | Out-File -FilePath flagshipSigningKey.txt | ||
|
||
- name: Decode signing Key | ||
shell: pwsh | ||
run: certutil -decode .\flagshipSigningKey.txt .\flagshipSigningKey.snk | ||
|
||
- name: Build nuget | ||
run: MSBuild.exe -t:pack -property:Configuration=Release -property:SignAssembly=True -property:AssemblyOriginatorKeyFile=flagshipSigningKey.snk | ||
working-directory: Flagship | ||
|
||
- name: set Nuget api key | ||
run: nuget setApiKey ${{ secrets.NUGET_APIKEY }} | ||
|
||
- name: Push Nuget Packages | ||
run: nuget push Flagship.SDK.*.nupkg -Source https://api.nuget.org/v3/index.json | ||
working-directory: Flagship/NugetPackageRelease | ||
|
||
# - name: Upload coverage to codecov | ||
# uses: codecov/codecov-action@v2 | ||
# with: | ||
# files: ./CoverageResults.xml |
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