diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 0218e88..f5b89a5 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -15,8 +15,41 @@ on: - "*.*.*" jobs: + # On pull requests, only linux-x64 runs, to prove AOT still links without burning the full matrix + # on packages nobody sees. All five run on push, where the packages are actually uploaded. + aot-pack: + runs-on: ${{ matrix.runner }} + name: AOT pack (${{ matrix.rid }}) + strategy: + fail-fast: false + matrix: + include: ${{ fromJSON(github.event_name == 'pull_request' + && '[{"rid":"linux-x64","runner":"ubuntu-latest"}]' + || '[{"rid":"linux-x64","runner":"ubuntu-latest"},{"rid":"linux-arm64","runner":"ubuntu-24.04-arm"},{"rid":"win-x64","runner":"windows-latest"},{"rid":"win-arm64","runner":"windows-11-arm"},{"rid":"osx-arm64","runner":"macos-latest"}]') }} + steps: + - uses: actions/checkout@v5 + with: + fetch-depth: 1 + - uses: actions/setup-dotnet@v5 + with: + dotnet-version: | + 10.0.x + + - run: dotnet pack src/release-notes/release-notes.csproj -c Release -r ${{ matrix.rid }} -o build/output + name: Pack native-AOT tool for ${{ matrix.rid }} + shell: bash + + - name: Upload per-RID package + if: github.event_name == 'push' + uses: actions/upload-artifact@v4 + with: + name: nupkg-${{ matrix.rid }} + path: build/output/*.nupkg + if-no-files-found: error + build: runs-on: ubuntu-latest + needs: aot-pack steps: - uses: actions/checkout@v5 with: @@ -37,6 +70,15 @@ jobs: name: Build - run: ./build.sh generatepackages -s true name: Generate local nuget packages + + - name: Download per-RID AOT packages + if: github.event_name == 'push' + uses: actions/download-artifact@v4 + with: + pattern: nupkg-* + path: build/output + merge-multiple: true + - run: ./build.sh validatepackages -s true name: "validate *.npkg files that were created" - run: ./build.sh generateapichanges -s true diff --git a/Directory.Build.props b/Directory.Build.props index d05fa3e..169a30a 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -3,6 +3,8 @@ canary.0 0.1 + + latest diff --git a/README.md b/README.md index e0e9507..b33dc71 100644 --- a/README.md +++ b/README.md @@ -14,39 +14,98 @@ Distributed as a .NET tool so install using the following dotnet tool install release-notes ``` -## Run +On Linux, Windows and macOS/arm64, this resolves to a self-contained native-AOT executable — no +shared .NET runtime required, and no first-run JIT warmup. Everywhere else, it falls back to a +framework-dependent build (requires the .NET runtime the tool targets to already be installed). + +## Run ```bat -dotnet release-notes +dotnet release-notes --version [options] +``` + +You can omit `dotnet` if you install this as a global tool. + +> [!IMPORTANT] +> Starting from `1.0.0`, every invocation requires an explicit command name (`generate`, +> `apply-labels`, `find-previous`, `current-version` or `create-release`) — there is no longer a bare +> `release-notes ...` shorthand for `generate`. `--label` also changes from two tokens +> (`--label