-
-
Notifications
You must be signed in to change notification settings - Fork 0
54 lines (45 loc) · 1.41 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
name: Build
on:
push:
branches: ["master"]
pull_request:
branches: ["master"]
jobs:
build:
permissions:
contents: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup .NET
uses: actions/setup-dotnet@v2
with:
dotnet-version: 6.0.x
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Restore dependencies
run: dotnet restore
- name: Install GitVersion
uses: gittools/actions/gitversion/setup@v0.9.7
with:
versionSpec: "5.x"
- name: Determine Version
uses: gittools/actions/gitversion/execute@v0.9.7
with:
additionalArguments: '/updateprojectfiles /overrideconfig "mode=Mainline"'
- name: Build (Release)
run: dotnet build . --configuration Release -p:Version=$GitVersion_SemVer
- name: GH Release
uses: softprops/action-gh-release@v1
if: ${{ !env.ACT && github.event_name == 'push' }}
with:
body: Automatic pre-release of ${{ env.GitVersion_SemVer }} for ${{ env.GitVersion_ShortSha }}
name: v${{ env.GitVersion_SemVer }}
files: |
./bin/Release/net6.0/CrimsonFAQ.dll
CHANGELOG.md
fail_on_unmatched_files: true
prerelease: true
tag_name: v${{ env.GitVersion_SemVer }}