feat: add GitHub Actions CI/CD workflows and local test runner#11
Merged
Conversation
- ci.yml: build & test matrix across net8.0, net9.0, net10.0 on push/PR - release.yml: build, test, pack, tag-guard, GitHub Release, NuGet push - System.Text.Json.Stream.CI.slnf: solution filter (library + tests only, excludes benchmarks) - ci-cd-test-run.ps1: local runner with lint, dry-run, and full act execution modes
There was a problem hiding this comment.
Pull request overview
Adds CI and release automation for the Utf8JsonAsyncStreamReader repo via GitHub Actions, plus a local PowerShell runner to lint/dry-run/execute workflows using actionlint + act.
Changes:
- Introduces CI workflow with PR branch-name validation and a test matrix across net8.0/net9.0/net10.0.
- Introduces release workflow that builds/tests, packs, creates a GitHub Release, and pushes packages to NuGet.
- Adds a CI-focused solution filter and a local CI/CD runner script.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 5 comments.
| File | Description |
|---|---|
src/System.Text.Json.Stream.CI.slnf |
Adds a solution filter to scope CI builds/tests to the library + tests. |
ci-cd-test-run.ps1 |
Adds a local runner for actionlint + act modes (lint/dry/ci/all) with some output parsing. |
.github/workflows/ci.yml |
Adds CI workflow with branch validation and a TFM matrix test run plus artifact upload. |
.github/workflows/release.yml |
Adds release workflow for master pushes to publish NuGet packages and create GitHub releases. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- ci.yml: add --no-build --no-restore to dotnet test step - ci.yml: clarify continue-on-error intent with comment (env.ACT approach rejected — trips actionlint) - release.yml: add --no-build --no-restore to all three dotnet test steps - ci-cd-test-run.ps1: downgrade dotnet host check to warning (act installs .NET in runner) - ci-cd-test-run.ps1: add Test-Tool 'docker' check before docker info for clearer error on missing vs. stopped Docker
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.
Summary
Adds full GitHub Actions CI/CD automation for the
Utf8JsonAsyncStreamReaderproject.Changes
.github/workflows/ci.ymlfeature/**,fix/**,hotfix/**and PRs todevelop/mastervalidate-branchjob: enforcesfeature/,fix/, orhotfix/prefix on PR source branchesbuild-and-testjob: matrix across net8.0, net9.0, net10.0 with all three SDKs installed.trxtest result artefacts (withcontinue-on-error: truefor knownactlocal limitation).github/workflows/release.ymlmasterSystem.Text.Json.Stream.csprojUtf8JsonAsyncStreamReader.nupkg+.snupkg(symbols enabled)ghCLI with both artefacts attached.nupkgand.snupkgto NuGet.org via${{ secrets.NUGET_API_KEY }}src/System.Text.Json.Stream.CI.slnfSystem.Text.Json.Stream.BenchmarksandSystem.Text.Json.Stream.Benchmarks.Oldci-cd-test-run.ps1lint(actionlint),dry(act -n),ci(full act),allmodes-Workflow ci|release|bothand-Job <name>targetingactWindows artifact-cache cleanup false-positivePre-merge validation
Utf8JsonAsyncStreamReader.2.1.0.nupkg+.snupkgproducedRequired setup (one-time, before first release)
Add
NUGET_API_KEYas a repository secret:Repository → Settings → Secrets and variables → Actions → New repository secret