diff --git a/.github/workflows/build_nupkg.yml b/.github/workflows/build_nupkg.yml new file mode 100644 index 0000000..d434e42 --- /dev/null +++ b/.github/workflows/build_nupkg.yml @@ -0,0 +1,44 @@ +name: Nuget Pack + +on: + push: + branches: [ "master" ] + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + with: + submodules: recursive + + - name: Setup .NET + uses: actions/setup-dotnet@v4 + with: + dotnet-version: 9.0.x + + - name: Restore dependencies + run: dotnet restore + + - name: Pack + run: dotnet pack + + - name: Upload NDecrypt Core package + uses: actions/upload-artifact@v4 + with: + name: 'NDecrypt Core Package' + path: 'NDecrypt.Core/bin/Release/*.nupkg' + + - name: Upload NDecrypt Core to rolling + uses: ncipollo/release-action@v1.14.0 + with: + allowUpdates: True + artifacts: 'NDecrypt.Core/bin/Release/*.nupkg' + body: 'Last built commit: ${{ github.sha }}' + name: 'Rolling Release' + prerelease: True + replacesArtifacts: True + tag: "rolling" + updateOnlyUnreleased: True + diff --git a/publish-nix.sh b/publish-nix.sh index a179726..ff5ddcd 100644 --- a/publish-nix.sh +++ b/publish-nix.sh @@ -64,6 +64,9 @@ if [ $NO_BUILD = false ]; then echo "Restoring Nuget packages" dotnet restore + # Create Nuget Packages + dotnet pack NDecrypt.Core/NDecrypt.Core.csproj --output $BUILD_FOLDER + # Build Program for FRAMEWORK in "${FRAMEWORKS[@]}"; do for RUNTIME in "${RUNTIMES[@]}"; do diff --git a/publish-win.ps1 b/publish-win.ps1 index c23db4c..b4cac29 100644 --- a/publish-win.ps1 +++ b/publish-win.ps1 @@ -55,6 +55,9 @@ if (!$NO_BUILD.IsPresent) { Write-Host "Restoring Nuget packages" dotnet restore + # Create Nuget Package + dotnet pack NDecrypt.Core\NDecrypt.Core.csproj --output $BUILD_FOLDER + # Build Program foreach ($FRAMEWORK in $FRAMEWORKS) { foreach ($RUNTIME in $RUNTIMES) {