diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5482c7d4..4179413e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -67,12 +67,12 @@ jobs: name: ${{ matrix.name }} path: nuget.package/runtimes/${{ matrix.name }} package: - name: Create package - needs: build - runs-on: ubuntu-24.04 - env: - DOTNET_NOLOGO: true - steps: + name: Create package + needs: build + runs-on: ubuntu-24.04 + env: + DOTNET_NOLOGO: true + steps: - name: Checkout uses: actions/checkout@v4.2.2 with: @@ -92,3 +92,10 @@ jobs: with: name: NuGet package path: ./nuget.package/*.nupkg + - name: Push package to feed 🐙 + id: push-feed + shell: bash + env: + FEED_API_KEY: ${{ secrets.FEED_API_KEY }} + FEED_SOURCE: ${{ secrets.FEED_SOURCE }} + run: dotnet nuget push ./nuget.package/*.nupkg --api-key "$FEED_API_KEY" --source "$FEED_SOURCE" diff --git a/README.md b/README.md index a6f68879..e96e1453 100644 --- a/README.md +++ b/README.md @@ -86,7 +86,7 @@ dotnet tool install --global minver-cli Once that is installed, running the `minver` command will output a version: ``` -MinVer: Using { Commit: 2453a6d, Tag: '2.0.312', Version: 2.0.312, Height: 3 }. +MinVer: Using { Commit: 2453a6d, Tag: '2.0.323', Version: 2.0.323, Height: 3 }. MinVer: Calculated version 2.0.313-alpha.0.3. 2.0.313-alpha.0.3 ``` @@ -100,6 +100,25 @@ nuget.exe Pack nuget.package/NativeBinaries.nuspec -Version -NoPackage Where `` is the version from the MinVer tool or manually chosen version. +## Releasing this Octopus fork + +Releases are triggered by pushing a git tag. The tag format is: + +``` +-octopus. +``` + +Where `` is the version from the upstream libgit2sharp.nativebinaries repo (e.g., `2.0.323`) and `` is an incrementing number starting at 1. The incrementing number resets to 1 when the upstream version changes. + +For example, for upstream version `2.0.323`: + +``` +git tag 2.0.323-octopus.1 +git push origin 2.0.323-octopus.1 +``` + +This triggers CI, which builds all native binaries, packs the NuGet package with the tag as its version, and pushes it to the configured feed. + ## Notes on Visual Studio Visual Studio 2019 is required to build the Windows native binaries, however you