You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Reported bug: the Plan/version logic resolves a prerelease on merge to the default branch (e.g. GoogleFonts run 29202094727). The desired model is: a prerelease exists only while a PR is open; when a change lands on the default branch it must be a stable release or nothing — never a prerelease. The clean way to make that structural (rather than a conditional) is to drive stable releases from a push to main trigger (#84) instead of the pull_request: closed (merged) event.
Consolidate the framework scripts into the PSMA action library first, then build push-to-main in one place.
Decision
Consolidate into PSMA first, then build #84 there. The reported bug is already neutralized by the architecture-independent stopgap Resolve-PSModuleVersion#11 ("prerelease only for open PRs"), so there is no pressure to rush #84 onto the old layout and port it twice.
Why consolidate first
#84 changes exactly the scripts PSMA will absorb, so doing it on the scattered repos is largely throwaway:
Get-PSModuleSettings — ReleaseType/Run.* are keyed off isMergedPR (pull_request closed+merged); push-to-default needs new detection.
Resolve-PSModuleVersion — version comes from PR labels; on push the PR must be resolved from the merge commit (GET /repos/{owner}/{repo}/commits/{sha}/pulls, verified working).
Publish-PSModule — the blocker: both src/publish.ps1 and src/cleanup.ps1 hard-throw without a pull_request and derive everything from it (head ref as prerelease --target, PR number for comments, title/body for notes). This is where the prerelease-path (PR) vs stable-path (push) split belongs (see Publish-PSModule: Split Gallery publishing from GitHub Release creation #330).
In the scattered model the event→prerelease/stable routing is smeared across 3 action repos + workflow.yml + every consumer caller (3 releases, 3 pin bumps). In PSMA it is one main.ps1 dispatcher deciding the route once.
The PSMA library
PSModule/PSMA — "PSModule Actions: one library-backed action dispatched by Mode". One internal PS module holds all framework logic (settings/version/build/test/publish/docs/coverage/results); one composite action switches on Mode. Foundation: PR #1initialize-psma-library (green, mergeable; currently working skeletons with PORT FROM: markers). Cross-repo action resolution is solved via the OIDC job_workflow_sha self-checkout (proven), so consumers pass nothing extra.
Context
Reported bug: the Plan/version logic resolves a prerelease on merge to the default branch (e.g. GoogleFonts run 29202094727). The desired model is: a prerelease exists only while a PR is open; when a change lands on the default branch it must be a stable release or nothing — never a prerelease. The clean way to make that structural (rather than a conditional) is to drive stable releases from a
pushtomaintrigger (#84) instead of thepull_request: closed(merged) event.Two ways to get there:
Decision
Consolidate into PSMA first, then build #84 there. The reported bug is already neutralized by the architecture-independent stopgap Resolve-PSModuleVersion#11 ("prerelease only for open PRs"), so there is no pressure to rush #84 onto the old layout and port it twice.
Why consolidate first
#84changes exactly the scripts PSMA will absorb, so doing it on the scattered repos is largely throwaway:Get-PSModuleSettings—ReleaseType/Run.*are keyed offisMergedPR(pull_requestclosed+merged); push-to-default needs new detection.Resolve-PSModuleVersion— version comes from PR labels; onpushthe PR must be resolved from the merge commit (GET /repos/{owner}/{repo}/commits/{sha}/pulls, verified working).Publish-PSModule— the blocker: bothsrc/publish.ps1andsrc/cleanup.ps1hard-throwwithout apull_requestand derive everything from it (head ref as prerelease--target, PR number for comments, title/body for notes). This is where the prerelease-path (PR) vs stable-path (push) split belongs (see Publish-PSModule: Split Gallery publishing from GitHub Release creation #330).In the scattered model the event→prerelease/stable routing is smeared across 3 action repos +
workflow.yml+ every consumer caller (3 releases, 3 pin bumps). In PSMA it is onemain.ps1dispatcher deciding the route once.The PSMA library
PSModule/PSMA— "PSModule Actions: one library-backed action dispatched byMode". One internal PS module holds all framework logic (settings/version/build/test/publish/docs/coverage/results); one composite action switches onMode. Foundation: PR #1initialize-psma-library(green, mergeable; currently working skeletons withPORT FROM:markers). Cross-repo action resolution is solved via the OIDCjob_workflow_shaself-checkout (proven), so consumers pass nothing extra.Plan
Phase 1 — land the PSMA foundation
Phase 2 — port real logic into PSMA (one PR each, keep tests/fixtures — closes #347)
Install-PSModuleHelpers(the shared leaf) → module private helpersGet-PSModuleSettings→Mode: SettingsResolve-PSModuleVersion→Mode: VersionBuild-PSModule→Mode: BuildTest-PSModule/Get-PesterCodeCoverage/Get-PesterTestResults→ test modesDocument-PSModule→Mode: DocsPublish-PSModule→Mode: Publish(split Gallery publish vs GitHub Release — Publish-PSModule: Split Gallery publishing from GitHub Release creation #330/Separate GitHub Release creation from PowerShell Gallery publishing #210)Phase 3 — re-point orchestration
Process-PSModulereusable sub-workflows at PSMA (self-checkout via OIDCjob_workflow_sha).Phase 4 — push-to-main release model (#84) in PSMA
push: branches: [main]to the caller template (+ consumers).push: map merge commit → PR (labels/title/body/head ref) via the commits→pulls API.pull_request(open) → prerelease/preview;pushto default → stable release;pull_request: closed→ prerelease cleanup only.pull_request: closed(merged) release path.Acceptance criteria
pushtomain, with PR context resolved from the merge commit.Related