Skip to content

Commit f66d75b

Browse files
author
Petr Sramek
committed
wooohoo
1 parent dcac09b commit f66d75b

File tree

3 files changed

+45
-46
lines changed

3 files changed

+45
-46
lines changed

.github/actions/build-dotnet.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
on:
2+
workflow_call:
3+
inputs:
4+
search-pattern: # Solution(s) or project(s) to build e.g. src/**/*.csproj
5+
description: 'Solution(s) or project(s) to build e.g. src/**/*.csproj'
6+
required: false
7+
default: '**/*.*'
8+
dotnet-version: # .NET version(s) to be installed
9+
description: '.NET version(s) to be installed'
10+
required: false
11+
default: '9.x'
12+
configuration:
13+
description: 'Build Configuration'
14+
required: false
15+
default: 'Release'
16+
platform:
17+
description: 'Build Platform'
18+
required: false
19+
default: 'AnyCPU'
20+
21+
jobs:
22+
build-jon:
23+
steps:
24+
- name: Install .NET 9
25+
uses: actions/setup-dotnet@v4
26+
with:
27+
dotnet-version: $DOTNET_VERSION
28+
- name: Restore
29+
run: dotnet restore
30+
- name: Build
31+
run: dotnet build $SEARCH_PATTERN --no-restore --configuration $CONFIGURATION --platform $PLATFORM
32+
env:
33+
SEARCH_PATTERN: ${{ inputs.search-pattern }}
34+
DOTNET_VERSION: ${{ inputs.dotnet-version }}
35+
CONFIGURATION: ${{ inputs.configuration }}
36+
PLATFORM: ${{ inputs.platform }}

.github/templates/build.yml

Lines changed: 0 additions & 37 deletions
This file was deleted.

.github/workflows/dotnet.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,15 @@ jobs:
1414

1515
steps:
1616
- uses: actions/checkout@v3
17-
- uses: petesramek/polyline-algorithm-csharp/.github/templates/build@9f04b48af7fbea3556d6e803665b36481be33e4d
18-
- name: Install .NET 9
19-
uses: actions/setup-dotnet@v4
20-
with:
21-
dotnet-version: 9.x
22-
- name: Restore
23-
run: dotnet restore ./src/**/*.csproj
24-
- name: Build
25-
run: dotnet build ./src/**/*.csproj --no-restore --configuration Release
17+
- uses: ./.github/actions/build-dotnet
18+
# - name: Install .NET 9
19+
# uses: actions/setup-dotnet@v4
20+
# with:
21+
# dotnet-version: 9.x
22+
# - name: Restore
23+
# run: dotnet restore ./src/**/*.csproj
24+
# - name: Build
25+
# run: dotnet build ./src/**/*.csproj --no-restore --configuration Release
2626
- name: Upload
2727
uses: actions/upload-artifact@v4
2828
with:

0 commit comments

Comments
 (0)