Skip to content

Latest commit

 

History

History
44 lines (28 loc) · 3.86 KB

File metadata and controls

44 lines (28 loc) · 3.86 KB

RestClient.Net — Agent Instructions

This is a C# and F# library repository containing RestClient.Net, Outcome, the Exhaustion analyzer, OpenAPI/MCP generators, and samples. Website/ contains the Eleventy documentation site.

AgentPMO scope

This repository uses a light AgentPMO integration: skills, existing CI, CodeQL, and staged Dependabot updates. Use the installed skills in .agents/skills/ for relevant tasks. Follow the user's requested scope and existing authorization; a skill does not authorize a broader standards rollout. The upstream clone is separate at ../AgentPMOWorkflow.

Commands

The existing dotnet commands are the local equivalents of the Makefile commands in upstream skills. Read .github/workflows/ci.yml for the exact CI sequence.

Purpose Command
Setup dotnet tool restore, python3 scripts/release.py pack-analyzer, then dotnet restore RestClient.sln --source .artifacts/packages --source https://api.nuget.org/v3/index.json
Build dotnet build RestClient.sln --configuration Release --no-restore /warnaserror
Analysis dotnet build RestClient.sln --configuration Release --no-restore /p:RunAnalyzers=true /p:TreatWarningsAsErrors=true
Format check dotnet csharpier --check .
Format dotnet csharpier .
Solution tests dotnet test RestClient.sln --configuration Release --no-build
F# tests outside the solution dotnet test RestClient.Net.FsTest/RestClient.Net.FsTest.fsproj --configuration Release
Mutation tests Run dotnet stryker --break-at 100 in RestClient.Net.CsTest/
Website build Run npm ci and npm run build in Website/

Use .NET 8 and 9 runtimes for the repository's targets. Run focused tests while iterating, then the relevant CI checks. Preserve the existing assertions and regression coverage. Generated sample code is regenerated by the existing build targets.

Website

The Eleventy site uses local layouts and a shared .prose class for docs, API references, and blog posts. Total shipped CSS must remain at or below 2,500 raw UTF-8 bytes, including every stylesheet. Do not bypass the budget with inline styles, external CSS, or JavaScript that injects CSS. npm run build enforces the budget and checks generated links and metadata.

API reference pages are exported from C# declarations and XML comments by Website/tools/ApiDocs/; edit the source rather than generated Website/src/api/reference/ files. Run npm run test:unit, npm run build, and npm test in Website/. The deployment workflow also verifies the GitHub Pages path prefix. See Website/README.md.

Git and CI

Use a feature branch and a PR to main; derive the PR title and description from the diff with origin/main. Follow the user's authorization for committing, pushing, and merging. Monitor the latest PR commit's checks and resolve failures before merging. Do not add AI co-author trailers.

Dependabot updates accumulate on dependabot-upgrades; ordinary CI and CodeQL run on the consolidation PR to main, not on each bot bump. Never publish packages or create release tags as part of an ordinary PR.

When a release is authorized, use .github/workflows/publish-restclient.yml. It builds and tests both packages, publishes and verifies Exhaustion first, then publishes RestClient.Net and verifies a fresh NuGet consumer. ExhaustionVersion in Directory.Build.props is shared by the analyzer and all references. See scripts/README.md for package verification and immutable-version rules.

Integration-test isolation

The Nuclia integration fixture starts Docker Compose and removes its project's containers and volumes. If the host already has services, use an isolated COMPOSE_PROJECT_NAME and Compose configuration with non-conflicting ports before running it. Keep the heap-limited child processes in the Exhaustion regression tests intact.