Skip to content

Dogfood BettererNet on its own repo + alpha release pipeline - #5

Merged
timonkrebs merged 4 commits into
mainfrom
claude/charming-bell-iq2emr
Jun 18, 2026
Merged

Dogfood BettererNet on its own repo + alpha release pipeline#5
timonkrebs merged 4 commits into
mainfrom
claude/charming-bell-iq2emr

Conversation

@timonkrebs

Copy link
Copy Markdown
Owner

Builds on #4 (merged). Two steps toward a real release: make BettererNet guard its own codebase, then add the pipeline to publish it.

Dogfooding

Pointing the tool at its own repo immediately surfaced a real gap, which this PR fixes:

  • Found + fixed: regex tests globbed with no bin/obj exclusion, so **/*.cs would also scan generated build output — giving non-deterministic counts between a fresh checkout and a built CI tree (every adopter hits this on day one). Added an excludes option to BettererRegexTest; the declarative config now defaults to skipping bin/obj.
  • Added a root betterer.json guarding the source: no sync-over-async (2 real calls in BettererHistoryReporter, tracked as acknowledged debt), no #pragma warning disable, no async void, no NotImplementedException (the last three locked at zero).
  • Recorded the baseline (.betterer.results) and wired betterernet ci into CI.
  • Verified end-to-end on this repo: baseline → ci exits 0; a planted #pragma warning disable[worse] with exact file:line and exit 1; removed → green again.

Alpha release prep

  • .github/workflows/release.yml — on a v* tag (or manual dispatch with a version), builds → tests → packs → dotnet nuget push all 13 packages to nuget.org (--skip-duplicate), gated on a NUGET_API_KEY secret.
  • CHANGELOG.md documenting the 0.1.0-alpha surface and RELEASING.md with the cut-a-release steps.
  • Refreshed the stale README CLI description and updated the ROADMAP.

Verification

  • Full suite 148 tests green (2 new); dotnet pack13 packages; both workflow YAMLs parse.
  • Not verifiable in CI here: the actual nuget push (needs the key + live nuget.org).

To ship the alpha after merge

  1. Add repo secret NUGET_API_KEY (Settings → Secrets and variables → Actions).
  2. git tag v0.1.0-alpha && git push origin v0.1.0-alpha → the workflow publishes.

https://claude.ai/code/session_01V1phdgDossB7htzxcbZTNF


Generated by Claude Code

claude added 2 commits June 14, 2026 22:25
Add a regex `excludes` option so globbing real .NET repos doesn't count
generated build output; the declarative config defaults to skipping
bin/obj. This gap surfaced immediately when pointing the tool at this repo.

Add a root betterer.json guarding the source against new sync-over-async
(2 acknowledged in BettererHistoryReporter), #pragma warning disable,
async void, and NotImplementedException. Record the baseline in
.betterer.results and run `betterernet ci` as a CI step.

Docs: document excludes + the bin/obj default; refresh the stale CLI
description; note the dogfooding in the README.
Add a release workflow that builds, tests, packs, and pushes all 13
packages to nuget.org on a `v*` tag (or manual dispatch with a version),
gated on a NUGET_API_KEY secret. Add CHANGELOG.md documenting the 0.1.0-alpha
surface and RELEASING.md with the cut-a-release steps. Update ROADMAP to note
the release pipeline and dogfooding.
Copilot AI review requested due to automatic review settings June 14, 2026 23:10

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR dogfoods BettererNet against its own repository by committing a declarative betterer.json + baseline results and wiring betterernet ci into CI, and it adds an alpha release pipeline for publishing NuGet packages via a tag-triggered workflow. It also extends the regex test integration to support glob excludes and makes the declarative config default to skipping generated bin/obj output.

Changes:

  • Add excludes support to BettererRegexTest and default betterer.json-driven regex tests to exclude **/bin/** and **/obj/**.
  • Add repo-level dogfooding configuration (betterer.json, .betterer.results) and run the self-check in CI.
  • Add a tag/manual-dispatch GitHub Actions release workflow plus release documentation (CHANGELOG/RELEASING/README/ROADMAP updates).

Reviewed changes

Copilot reviewed 13 out of 13 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
tests/BettererNet.Tests/BettererRegexTestTests.cs Updates regex test calls for new signature and adds coverage for exclude globs.
tests/BettererNet.Tests/BettererConfigFileTests.cs Adds test ensuring declarative regex config excludes bin/obj by default.
src/BettererNet.Regex/BettererRegexTest.cs Introduces excludes to the regex test implementation and applies it to scan + fingerprint.
src/BettererNet.Cli/BettererConfigFile.cs Adds default bin/obj excludes for declarative regex tests.
ROADMAP.md Updates roadmap to reflect dogfooding and release workflow completion.
RELEASING.md Adds step-by-step NuGet release instructions.
README.md Refreshes CLI description and documents self-guarding behavior.
DOCUMENTATION.md Documents regex excludes and the default bin/obj behavior in declarative config.
CHANGELOG.md Adds an initial 0.1.0-alpha changelog entry.
betterer.json Adds a repo-level BettererNet config to guard the codebase.
.github/workflows/release.yml Adds a tag/manual-trigger release workflow to pack and push NuGet packages.
.github/workflows/ci.yml Adds a CI step to run betterernet ci against the committed baseline.
.betterer.results Adds the committed baseline results used by CI dogfooding.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/BettererNet.Regex/BettererRegexTest.cs
Push the 13 BettererNet.* packages by name (and fail if an expected one is
missing) instead of artifacts/*.nupkg, so a new or internal project can never
be published to nuget.org by accident.
@timonkrebs

Copy link
Copy Markdown
Owner Author

@codex make a review!

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 09796100fc

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .github/workflows/release.yml Outdated
Comment thread src/BettererNet.Regex/BettererRegexTest.cs
Comment thread RELEASING.md Outdated
- Validate the resolved version as SemVer and pass the manual input via env
  rather than inline ${{ }} interpolation, closing a shell-injection vector
  on workflow_dispatch and rejecting malformed versions.
- Add a dry_run input (default true) so manual runs pack-only by default;
  tag pushes still publish. Fixes RELEASING.md describing manual runs as a
  dry run when they actually pushed to nuget.org.
- Document the pre-1.0 / ConfigLoader binary-compat policy in RELEASING.md.
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, you can upgrade your account or add credits to your account and enable them for code reviews in your settings.

@timonkrebs
timonkrebs merged commit 36eb6a9 into main Jun 18, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants