Properly configured build actions
Some checks failed
Build and publish MycroForge.CLI / test (push) Failing after 50s
Test MycroForge.CLI / test (push) Has been skipped

This commit is contained in:
mdnapo 2024-10-06 13:50:21 +02:00
parent a1ffc51a57
commit 165d97245d
3 changed files with 8 additions and 6 deletions

View File

@ -5,14 +5,12 @@ on: [ push ]
jobs:
test:
runs-on: ubuntu-latest
# if: gitea.ref == 'refs/heads/main'
if: gitea.ref == 'refs/heads/main'
steps:
- uses: https://github.com/actions/checkout@v4
- uses: https://github.com/actions/setup-dotnet@v4
with:
dotnet-version: '8.x'
# - name: "Build NuGet package"
# run: cd MycroForge.CLI && dotnet pack -v d
- name: "Build and publish NuGet package"
run: |
# Build the NuGet package
@ -25,5 +23,7 @@ jobs:
--store-password-in-clear-text \
https://git.devdisciples.com/api/packages/devdisciples/nuget/index.json
VERSION=$(grep '<Version>' < MycroForge.CLI.csproj | sed 's/.*<Version>\(.*\)<\/Version>/\1/')
# Push the package
dotnet nuget push nupkg/MycroForge.CLI.1.0.1.nupkg --source devdisciples
dotnet nuget push nupkg/MycroForge.CLI.$VERSION.nupkg --source devdisciples

View File

@ -5,7 +5,7 @@ on: [ push ]
jobs:
test:
runs-on: ubuntu-latest
if: gitea.ref == 'refs/heads/main'
if: gitea.ref == 'refs/heads/develop'
steps:
- uses: https://github.com/actions/checkout@v4
- uses: https://github.com/actions/setup-dotnet@v4

View File

@ -2,4 +2,6 @@
dotnet pack -v d
dotnet nuget push nupkg/MycroForge.CLI.1.0.0.nupkg --source devdisciples
VERSION="1.0.0"
dotnet nuget push nupkg/MycroForge.CLI.$VERSION.nupkg --source devdisciples