-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use GitHub Actions instead of AppVeyor
- Loading branch information
1 parent
453bfb4
commit 40e65c3
Showing
8 changed files
with
2,190 additions
and
456 deletions.
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
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,62 @@ | ||
name: Build | ||
on: | ||
push: | ||
branches: | ||
- main | ||
- 'features/**' | ||
paths-ignore: | ||
- 'docs/**' | ||
- .editorconfig | ||
- LICENSE | ||
- README.md | ||
jobs: | ||
Build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
- name: Install latest .NET SDK | ||
run: ./build/dotnet-install.sh | ||
- name: Restore .NET tools | ||
run: dotnet tool restore | ||
- name: Build | ||
run: | | ||
dotnet cake build.cake --bootstrap | ||
dotnet cake build.cake --pack | ||
- name: Upload NuGet packages | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: packages | ||
path: ./artifacts/packages | ||
- name: Upload dotnet test results | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: tests-results | ||
path: ./artifacts/test-results/*.trx | ||
if: ${{ always() }} | ||
- name: Report test results | ||
uses: dorny/[email protected] | ||
continue-on-error: true | ||
if: ${{ always() }} | ||
with: | ||
name: Test results | ||
path: 'artifacts/test-results/*.trx' | ||
reporter: dotnet-trx | ||
- name: Create GitHub release on main branch | ||
if: ${{ github.ref_name == 'main' }} | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
touch empty-release-notes.txt | ||
gh release create v${{ env.PACKAGE_VERSION }} --title v${{ env.PACKAGE_VERSION }} ./artifacts/packages/* --target ${{ github.sha }} --repo ${{ github.repository }} --notes-file empty-release-notes.txt | ||
- name: Create GitHub prerelease on features branches | ||
if: ${{ startsWith(github.ref_name, 'features/') }} | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
touch empty-release-notes.txt | ||
gh release create v${{ env.PACKAGE_VERSION }} --title v${{ env.PACKAGE_VERSION }} ./artifacts/packages/* --target ${{ github.sha }} --repo ${{ github.repository }} --notes-file empty-release-notes.txt --prerelease | ||
- name: Push NuGet package on main branch | ||
if: ${{ github.ref_name == 'main' }} | ||
run: dotnet nuget push ./artifacts/packages/*.nupkg --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_API_KEY }} |
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
This file was deleted.
Oops, something went wrong.
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
Oops, something went wrong.