forked from dotnet-state-machine/stateless
-
Notifications
You must be signed in to change notification settings - Fork 0
36 lines (28 loc) · 1.13 KB
/
BuildAndTestOnPullRequests.yml
File metadata and controls
36 lines (28 loc) · 1.13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: CI for Pull Requests
on:
push:
branches: [ dev ]
pull_request:
branches: [ dev ]
jobs:
Build_Stateless_solution:
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-dotnet@v5
with:
dotnet-version: '6.0.x'
- name: Install dependencies
run: dotnet restore
- name: Build Stateless solution
run: dotnet build Stateless.sln --configuration Release --no-restore
- name: Test Stateless
run: dotnet test --no-restore --no-build --configuration Release
- name: Authenticate to GitHub Packages
run: dotnet nuget add source --username USERNAME --password ${{ secrets.GITHUB_TOKEN }} --store-password-in-clear-text --name github "https://nuget.pkg.github.com/mindbox-cloud/index.json"
- name: Pack Release version
if: github.event_name == 'push'
run: dotnet pack src\Stateless\Stateless.csproj --version-suffix tealinc --configuration Release
- name: Publish Release version
if: github.event_name == 'push'
run: dotnet nuget push src\Stateless\bin\Release\*.nupkg --source "github"