@@ -3,47 +3,5 @@ on: [push, pull_request]
3
3
4
4
jobs :
5
5
build :
6
- runs-on : ubuntu-latest
7
- steps :
8
- - name : Checkout
9
- uses : actions/checkout@v1
10
- with :
11
- fetch-depth : 0
12
- - name : Setup .NET Core
13
- uses : actions/setup-dotnet@v1
14
- with :
15
- dotnet-version : 6.0.x
16
- - name : Build Reason
17
- run : " echo ref: ${{github.ref}} event: ${{github.event_name}}"
18
- - name : Build Version
19
- run : |
20
- dotnet tool install --global minver-cli --version 3.1.0
21
- version=$(minver --tag-prefix v)
22
- echo "MINVERVERSIONOVERRIDE=$version" >> $GITHUB_ENV
23
- - name : Build
24
- run : dotnet build --configuration Release
25
- - name : Run Tests
26
- run : dotnet test --configuration Release --no-build
27
- - name : Package
28
- if : github.event_name != 'pull_request'
29
- run : dotnet pack --configuration Release --no-build
30
- - name : Publish CI Packages
31
- if : github.event_name != 'pull_request'
32
- run : |
33
- for package in $(find -name "*.nupkg" | grep "minver" -v); do
34
- echo "${0##*/}": Pushing $package...
35
-
36
- # GitHub
37
- dotnet nuget push $package --source https://nuget.pkg.github.com/foundatiofx/index.json --api-key ${{ secrets.GITHUB_TOKEN }} --skip-duplicate
38
-
39
- # Feedz (remove once GitHub supports anonymous access)
40
- dotnet nuget push $package --source https://f.feedz.io/foundatio/foundatio/nuget --api-key ${{ secrets.FEEDZ_KEY }} --skip-duplicate
41
- done
42
- - name : Publish Release Packages
43
- if : startsWith(github.ref, 'refs/tags/v')
44
- run : |
45
- for package in $(find -name "*.nupkg" | grep "minver" -v); do
46
- echo "${0##*/}": Pushing $package...
47
- dotnet nuget push $package --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_KEY }} --skip-duplicate
48
- done
49
-
6
+ uses : FoundatioFx/Foundatio/.github/workflows/build-workflow.yml@master
7
+ secrets : inherit
0 commit comments