-
Notifications
You must be signed in to change notification settings - Fork 0
55 lines (44 loc) · 1.36 KB
/
build.yml
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
name: Build
on:
workflow_dispatch:
push:
branches:
- main
pull_request:
concurrency:
group: build_${{ github.ref_name }}
cancel-in-progress: true
jobs:
build:
permissions:
contents: read
attestations: write
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: |
8.0.x
- name: Define VERSION
run: |
echo "COMMIT=${GITHUB_SHA:0:7}"
echo "REPO_NAME=${GITHUB_REPOSITORY##*/}"
echo "BRANCH=${GITHUB_REF##*/}"
- name: Build (Debug)
run: dotnet build -c Debug
# - name: Test (Debug)
# run: dotnet test -c Debug --no-build -p:CollectCoverage=true -p:CoverletOutputFormat=opencover -p:Include="[Patreon.Api]*"
- name: Build (Release)
run: dotnet build -c Release
# - name: Test (Release)
# run: dotnet test -c Release --no-build -p:CollectCoverage=true -p:CoverletOutputFormat=opencover -p:Include="[Patreon.Api]*"
# - name: Upload Codecov
# uses: codecov/[email protected]
# with:
# token: ${{ secrets.CODECOV_TOKEN }}
# fail_ci_if_error: true