Skip to content

Commit

Permalink
Merge pull request #3 from Baseflow/develop
Browse files Browse the repository at this point in the history
Add publishing workflow
  • Loading branch information
ejorritsma authored Apr 22, 2024
2 parents 698e75b + fda77ba commit c7f5c00
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/BUILD_AND_TEST.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
branches: [ develop, main ]

jobs:
build_test_dstv_net:
build_test_rfid_controller:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
Expand Down
31 changes: 31 additions & 0 deletions .github/workflows/PUBLISH_PACKAGE.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Publish Package

on:
push:
branches: [ main ]
paths:
- 'SickRfid/SickRfid.csproj'
- 'Directory.Build.props'

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
name: Checkout repository
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: 7.0.x
- name: Restore dependencies
run: dotnet restore
- name: Test
run: dotnet test
- name: Build
run: dotnet build --configuration Release --no-restore
- name: Publish SickRfidController to NuGet
uses: brandedoutcast/publish-nuget@v2.5.2
with:
PROJECT_FILE_PATH: SickRfid/SickRfid.csproj
NUGET_KEY: ${{secrets.PUBLISH_TO_NUGET_ORG}}
3 changes: 3 additions & 0 deletions SickRfid/SickRfid.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,8 @@
<Content Include="..\.github\workflows\BUILD_AND_TEST.yml">
<Link>.github\workflows\BUILD_AND_TEST.yml</Link>
</Content>
<Content Include="..\.github\workflows\PUBLISH_PACKAGE.yml">
<Link>.github\workflows\PUBLISH_PACKAGE.yml</Link>
</Content>
</ItemGroup>
</Project>

0 comments on commit c7f5c00

Please sign in to comment.