Table of Contents

Releasing Mib.Cli

The mib CLI publishes to the agilecontent GitHub Packages NuGet feed: https://nuget.pkg.github.com/agilecontent/index.json.

Releases are tag-driven. The csproj <Version> is only the local-dev default — CI injects the real version from the tag. GH Packages versions are immutable: never reuse a version; every release is a new tag.

Cut a release (the normal path)

No file edit needed. Tag a tested commit and push the tag:

git tag mib-cli-v0.9.187
git push origin mib-cli-v0.9.187

.github/workflows/mcp_publish.yml then runs the test suite, packs Mib.Cli at 0.9.187, and pushes it to the feed. A manual re-publish is also available from the Actions tab (publish mib CLI → Run workflow, with an explicit version). Confirm the new version under the repo's Packages, then upgrade anywhere with dotnet tool update -g Mib.Cli.

One-time feed bootstrap (already done for the first release)

The first publish was done by hand to validate metadata + auth before automating:

cd mcp
dotnet pack src/Mib.ComponentRegistry/Mib.ComponentRegistry.csproj -c Release -p:Version=<X.Y.Z> -o ./nupkg
dotnet nuget push ./nupkg/Mib.Cli.<X.Y.Z>.nupkg \
  --source https://nuget.pkg.github.com/agilecontent/index.json --api-key <PAT>   # PAT needs write:packages

Consume (install the tool)

GH Packages requires auth even to read — a one-time source setup with a read:packages PAT:

dotnet nuget add source https://nuget.pkg.github.com/agilecontent/index.json \
  -n github-agilecontent -u <gh-username> -p <PAT> --store-password-in-clear-text
dotnet tool install -g Mib.Cli

Gotchas

  • SSO — a PAT must be authorized for the agilecontent SAML org or it 403s.
  • Classic PAT, not fine-grained, is the reliable token type for GH Packages NuGet. Scopes: write:packages to publish, read:packages to install.
  • --store-password-in-clear-text is required on macOS/Linux (dotnet nuget add source has no encrypted store there).
  • Immutable versions — a new release is always a new tag; CI uses --skip-duplicate so a re-run never fails.
  • Never add the GH feed to src/Mib.ComponentRegistry/nuget.config — that file is scoped to nuget.org so the build stays public/VPN-free. The feed lives in the user/global config (consume) and the --source flag (publish).
  • Only Mib.Cli ships. The sibling Mib.ComponentRegistry.Server (net10) is not packaged — the CLI self-hosts MCP via mib mcp serve.