From d469fb988f0d22aa483218982d4603e7c93dd553 Mon Sep 17 00:00:00 2001 From: Stone_Red <56473591+Stone-Red-Code@users.noreply.github.com> Date: Tue, 30 Dec 2025 19:33:22 +0100 Subject: [PATCH] Add GitHub Actions workflow for NuGet client package --- .github/workflows/nuget-client | 36 ++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 .github/workflows/nuget-client diff --git a/.github/workflows/nuget-client b/.github/workflows/nuget-client new file mode 100644 index 0000000..42f4a35 --- /dev/null +++ b/.github/workflows/nuget-client @@ -0,0 +1,36 @@ +name: Build and Push NuGet Client Package + +on: + workflow_dispatch: + push: + paths: + - 'src/RemoteExec.Client/**' + branches: + - main + +jobs: + build: + runs-on: ubuntu-latest + name: Build & Push Client NuGet Package + defaults: + run: + working-directory: "./src/RemoteExec.Client" + steps: + - uses: actions/checkout@v4 + + - name: Setup .NET + uses: actions/setup-dotnet@v4 + with: + dotnet-version: '10.0.x' + + - name: Restore dependencies + run: dotnet restore RemoteExec.Client.csproj + + - name: Build Client + run: dotnet build RemoteExec.Client.csproj --configuration Release --no-restore + + - name: Pack NuGet package + run: dotnet pack RemoteExec.Client.csproj --configuration Release --no-restore --output ./nuget + + - name: Push package to NuGet.org + run: dotnet nuget push ./nuget/*.nupkg --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json