-
Notifications
You must be signed in to change notification settings - Fork 0
42 lines (35 loc) · 982 Bytes
/
build-on-push.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
name: "build-on-push"
on:
push:
branches: [main, dev]
paths-ignore:
- '**.md'
- 'LICENSE'
- 'Resources/**'
pull_request:
branches: [main, dev]
paths-ignore:
- 'README.md'
- 'CHANGELOG.md'
- 'LICENSE'
env:
SOLUTION_PATH: MinecraftJars.sln
PACKAGE_OUTPUT_DIR: ${{ github.workspace }}\output
NUGET_SOURCE_URL: "https://api.nuget.org/v3/index.json"
jobs:
build:
name: "build"
runs-on: "ubuntu-latest"
steps:
- name: "Checkout"
uses: actions/checkout@v3
- name: "Install dotnet"
uses: actions/setup-dotnet@v2
with:
dotnet-version: "7.0.x"
- name: "Restore packages"
run: dotnet restore ${{ env.SOLUTION_PATH }}
- name: "Build project"
run: dotnet build ${{ env.SOLUTION_PATH }} --no-restore --configuration Release
- name: "Test project"
run: dotnet test ${{ env.SOLUTION_PATH }} --no-restore --configuration Release