Merge pull request #91 from strem-app/feature/dotnet-8 #260
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 And Test | |
on: [push] | |
jobs: | |
build-and-test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Setup .NET 8.0 | |
uses: actions/setup-dotnet@v2 | |
with: | |
dotnet-version: 8.0.x | |
- name: Run Build Script | |
shell: pwsh | |
run: | | |
./build.ps1 --buildNo='0.9.${{github.run_number}}' --target='build-and-test' | |
- name: Publish Test Results | |
uses: EnricoMi/publish-unit-test-result-action@v2 | |
with: | |
trx_files: "dist/*.trx" | |
- name: Code Coverage Report | |
uses: irongut/[email protected] | |
with: | |
filename: "dist/*.xml" | |
badge: true | |
output: both | |
format: markdown | |
indicators: true | |
package-and-release: | |
runs-on: windows-latest | |
if: startsWith(github.event.ref, 'refs/tags/') | |
needs: [build-and-test] | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Package App Script | |
shell: pwsh | |
run: ./build.ps1 --buildNo='0.9.${{github.run_number}}' --target='publish' | |
- name: Create Release | |
id: create_release | |
uses: actions/create-release@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag_name: ${{ github.ref }} | |
release_name: Release ${{ github.ref }} | |
draft: false | |
prerelease: false | |
- name: Upload App Release | |
uses: alexellis/[email protected] | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
asset_paths: '["./dist/*.zip"]' | |
- name: Publish To Nuget | |
run: dotnet nuget push "**/*.nupkg" -k ${{ secrets.NUGET_API_KEY }} -s https://api.nuget.org/v3/index.json |