diff --git a/.github/workflows/build-and-publish.yml b/.github/workflows/build-and-publish.yml new file mode 100644 index 0000000..c5044bd --- /dev/null +++ b/.github/workflows/build-and-publish.yml @@ -0,0 +1,69 @@ +name: build and publish + +on: + push: + branches: [master] + tags: ["v*"] + pull_request: + branches: [master] + +permissions: + contents: read + +jobs: + build: + name: build and test + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v7 + + - uses: actions/setup-dotnet@v6 + with: + dotnet-version: 10.0.x + + - name: Test + run: dotnet test EppLib.UnitTests/EppLib.UnitTests.csproj -c Release + + - name: Check tag matches package version + if: startsWith(github.ref, 'refs/tags/v') + run: | + version=$(dotnet msbuild EppLib/EppLib.csproj -getProperty:Version) + if [ "v$version" != "$GITHUB_REF_NAME" ]; then + echo "Tag $GITHUB_REF_NAME does not match package version $version" + exit 1 + fi + + - name: Pack + run: dotnet pack EppLib/EppLib.csproj -c Release -o artifacts + + - uses: actions/upload-artifact@v7 + with: + name: nupkg + path: artifacts/*.nupkg + + publish: + name: publish to NuGet + needs: build + if: startsWith(github.ref, 'refs/tags/v') + runs-on: ubuntu-latest + permissions: + id-token: write + steps: + - uses: actions/download-artifact@v8 + with: + name: nupkg + path: artifacts + + - uses: actions/setup-dotnet@v6 + with: + dotnet-version: 10.0.x + + # Trusted publishing: exchanges the GitHub OIDC token for a short-lived NuGet API key. + - name: NuGet login + id: login + uses: NuGet/login@v1 + with: + user: ademar + + - name: Push + run: dotnet nuget push "artifacts/*.nupkg" --api-key "${{ steps.login.outputs.NUGET_API_KEY }}" --source https://api.nuget.org/v3/index.json diff --git a/EppLib/EppLib.csproj b/EppLib/EppLib.csproj index 2f23479..bb767e7 100644 --- a/EppLib/EppLib.csproj +++ b/EppLib/EppLib.csproj @@ -1,178 +1,192 @@ - - - - net10.0 - EppLib - true - false - false - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + netstandard2.0;net10.0 + EppLib + EppLib + 1.4.0 + Code Maker Inc. and Contributors + EppLib.NET provides a library that makes easy for registrars to interact with registries implementing the Extensible Provisioning Protocol (EPP). Includes extensions for CIRA (.CA), Nominet (.UK), IIS (.SE), Verisign Namestore, LaunchPhase and SecDNS. + epp;registrar;registry;domain;rfc5730 + Apache-2.0 + https://github.com/CodeMakerInc/EppLib.NET + https://github.com/CodeMakerInc/EppLib.NET.git + git + README.md + Adds a net10.0 target alongside netstandard2.0. Fixes an infinite loop at 100% CPU in TcpTransport.Read when the server closes the connection (#46). + true + false + false + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/EppLib/EppLib.nuspec b/EppLib/EppLib.nuspec deleted file mode 100644 index 0795dab..0000000 --- a/EppLib/EppLib.nuspec +++ /dev/null @@ -1,20 +0,0 @@ - - - - EppLib - 1.0.0 - Code Maker Inc. and Contributors - ademar - https://github.com/ademar/EppLib.NET/blob/master/COPYING - false - EppLib.NET provides a library that makes easy for registrars to interact with registries implementing the EPP protocol. - -Our library is a complete implementation of the EPP specification. Have a look at the How to section for code examples and recipes. - - We now include EPP extensions for CIRA (the .CA registry), Nominet (the .UK registry) and IIS (the .SE registry). - EppLib.NET is a .NET library implementing the Extensible Provisioning Protocol (EPP) - - - - - \ No newline at end of file