diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index bfcb5eeef..07075dd73 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,5 +1,5 @@ # Hand-written (not auto-generated) — see Build.CI.GitHubActions.cs for the -# rationale (lets us bridge GitHub's NUGET_API_KEY secret to NUKE's +# rationale (lets us bridge GitHub's NUGET_API_KEY secret to Fallout's # NuGetApiKey parameter, which would otherwise have to share a name). name: release @@ -11,7 +11,6 @@ on: permissions: contents: write # for ICreateGitHubRelease (tag + GitHub release) - packages: write # in case we later push to GitHub Packages too jobs: release: @@ -31,8 +30,8 @@ jobs: - name: 'Run: Test, Pack, Publish' run: ./build.cmd Test Pack Publish env: - # Publish target is GitHub Packages on this fork, not nuget.org. - # GITHUB_TOKEN has packages:write per the permissions block above — - # no separate NuGet API key needed until the project rename. - NuGetApiKey: ${{ secrets.GITHUB_TOKEN }} + # Publish target is nuget.org now that Fallout.* rename has landed (#54). + # NUGET_API_KEY is an API key scoped to push Fallout.* packages, set in + # repo Settings → Secrets and variables → Actions. + NuGetApiKey: ${{ secrets.NUGET_API_KEY }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/CLAUDE.md b/CLAUDE.md index 50038d6c6..5baad3431 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -72,9 +72,7 @@ Validation workflows: **`ubuntu-latest`** runs on every PR targeting `main` (wit **Versioning:** [Nerdbank.GitVersioning](https://github.com/dotnet/Nerdbank.GitVersioning) — configured in `version.json` at the repo root. Major+minor is hand-bumped; patch comes from git-height. `main` is the public-release ref (stable versions); everything else gets prerelease tags. GitVersion is still installed as a transitional helper for `MajorMinorPatchVersion` in `Build.cs`; full removal is a follow-up. -**Release pipeline:** `.github/workflows/release.yml` — triggered on push to `main`, runs `./build.cmd Test Pack Publish`. **Publishes to GitHub Packages** (`https://nuget.pkg.github.com//index.json`) using the auto-provided `GITHUB_TOKEN` — no separate NuGet API key is needed. - -**Why not nuget.org?** Per Matt's wish, the "Nuke" name cannot be carried over to a successor project. The successor brand is Fallout. Until the breaking-rename phases land (#32, #34), packages stay on this fork's GitHub Packages feed. +**Release pipeline:** `.github/workflows/release.yml` — triggered on push to `main`, runs `./build.cmd Test Pack Publish`. **Publishes to nuget.org** (`https://api.nuget.org/v3/index.json`) under the `Fallout.*` package ID prefix, using the `NUGET_API_KEY` repo secret (a nuget.org API key scoped to push `Fallout.*`). Prefix reservation tracked in [#33](https://github.com/ChrisonSimtian/Fallout/issues/33). ## Conventions worth respecting diff --git a/build/Build.cs b/build/Build.cs index 50f882c06..836960e83 100644 --- a/build/Build.cs +++ b/build/Build.cs @@ -123,13 +123,9 @@ from framework in project.GetTargetFrameworks() [Parameter] [Secret] readonly string NuGetApiKey; - // Publishing to GitHub Packages on this fork until the post-hard-fork - // project rename lands. nuget.org would require the new name and can't - // be done under "Fallout.*" — see project_nuke_strategy memory note. - // Repository owner comes from GITHUB_REPOSITORY_OWNER, automatically set - // by GitHub Actions runners. ChrisonSimtian is the local-dev fallback. - string IPublish.NuGetSource => - $"https://nuget.pkg.github.com/{EnvironmentInfo.GetVariable("GITHUB_REPOSITORY_OWNER") ?? "ChrisonSimtian"}/index.json"; + // Publishing to nuget.org now that the Fallout.* rename has landed (#54). + // Requires NUGET_API_KEY in repo secrets — see release.yml. + string IPublish.NuGetSource => "https://api.nuget.org/v3/index.json"; string IPublish.NuGetApiKey => NuGetApiKey; Target IPublish.Publish => _ => _ @@ -148,7 +144,7 @@ IEnumerable NuGetPackageFiles .Executes(() => { var packagesDirectory = NuGetPackageResolver.GetPackagesDirectory(packagesConfigFile: BuildProjectFile); - var packageDirectories = packagesDirectory.GlobDirectories($"nuke.*/{DefaultDeploymentVersion}"); + var packageDirectories = packagesDirectory.GlobDirectories($"fallout.*/{DefaultDeploymentVersion}"); packageDirectories.DeleteDirectories(); });