Repository navigation
release: publish benchmark results to the README - #34
Merged
Merged
Conversation
- Add a '# Benchmarks' section at the end of README.md. - New .github/scripts/update-readme-benchmarks.ps1 replaces everything after '# Benchmarks' with the BenchmarkDotNet *-report-github.md report(s), preceded by a one-line note on how they were measured. Content above the heading is untouched; BOM and line endings are kept. - release.yml: run benchmarks right after the version bump, update the README, and commit Directory.Build.props + README.md together as the 'release: vX.Y.Z [skip ci]' commit. Build/pack/test then run from that commit, so the README inside the .nupkg (nuget.org page) and the SourceLink commit SHA both match what is pushed to main. - Build uses --no-incremental so the benchmark run's build output is never reused for the packed assemblies. - The README step is skipped on a re-run whose version commit was already pushed; the push step now keys off whether a commit was made. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012C6aJYkYBV2GSnSZwsd9GU
Reorders release.yml per review: bump -> build -> unit tests -> benchmarks -> Update Readme Benchmarks -> pack -> verify -> upload -> commit (version + README) -> push - Pack runs after the README update so the README inside the .nupkg (shown on nuget.org) carries this release's benchmark results. - The version commit is made once everything has passed, right before the push, instead of before the build. The package's SourceLink commit is the pre-release commit on main, which exists on GitHub and has identical sources; nothing is amended. - Drop --no-incremental from the build: verified that the unit-test and benchmark runs leave the built DLLs untouched (same hash and mtime). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012C6aJYkYBV2GSnSZwsd9GU
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Publish benchmark results to the README
Each release now writes its BenchmarkDotNet results into a
# Benchmarkssection at the end ofREADME.md. That updated README is committed together with the version bump.What changed
README.md: new# Benchmarkssection at the end. It starts with a placeholder line, which the first release replaces..github/scripts/update-readme-benchmarks.ps1(new):# Benchmarkswith the BenchmarkDotNet*-report-github.mdreport, preceded by a one-line note saying these are ShortRun numbers from a GitHub-hosted runner.release.yml: new order is bump → build → unit tests → benchmarks → Update Readme Benchmarks → pack → verify → upload → commitDirectory.Build.props+README.mdasrelease: vX.Y.Z [skip ci]→ push → publish..nupkg(shown on nuget.org) has this release's benchmark results.SourceLink
The package is built before the release commit exists, so its SourceLink commit is the commit the release started from (the PR merge on
main). That commit is on GitHub and has identical source files; the release commit only changesDirectory.Build.propsandREADME.md. So "go to source" works, and nothing is amended or rewritten.Validation
Simulated locally on a clone of
main(v1.1.13), running each PowerShell step the way Actions runs it:*-report-github.mdproduced.nupkgDirectory.Build.props+README.md; working tree clean afterwardsmain(exists on GitHub)Notes
🤖 Generated with Claude Code
https://claude.ai/code/session_012C6aJYkYBV2GSnSZwsd9GU