build: adopt PowerShellOrg reusable CI workflow - #497
HeyItsGilbert wants to merge 2 commits into
Conversation
cece4c3 to
1ea60f7
Compare
There was a problem hiding this comment.
🔵 Needs a closer look
The caller workflow is missing an explicit permissions: block, which can cause the reusable workflow to fail under read-only default GITHUB_TOKEN permissions.
Pull request overview
Adopts the PowerShellOrg organization-wide reusable GitHub Actions workflow for PSKoans CI by introducing a new .github/workflows/ci.yml that delegates all CI execution to PowerShellOrg/.github/.github/workflows/powershell-ci.yml@main.
Changes:
- Add a new GitHub Actions workflow (
.github/workflows/ci.yml) to run CI on pushes/tags, PRs, and manual dispatch. - Delegate CI execution to the PowerShellOrg reusable workflow (
powershell-ci.yml@main).
File summaries
| File | Description |
|---|---|
| .github/workflows/ci.yml | Adds a new CI workflow that calls the PowerShellOrg reusable CI workflow. |
Review details
Suppressed comments (1)
.github/workflows/ci.yml:16
- Reusable workflows cannot elevate GITHUB_TOKEN permissions; if the repo/org default token permissions are read-only, this call will fail to upload artifacts and publish PR suggestions/test results. Other repos consuming
PowerShellOrg/.github/.github/workflows/powershell-ci.yml@maindeclare explicit workflow-level permissions (e.g., checks/pull-requests write). Add an explicitpermissions:block in this caller workflow.
uses: PowerShellOrg/.github/.github/workflows/powershell-ci.yml@main
- Files reviewed: 1/1 changed files
- Comments generated: 0
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Test Results 4 files 104 suites 1m 38s ⏱️ For more details on these failures, see this check. Results for commit 5aa5f22. ♻️ This comment has been updated with latest results. |
Add .github/workflows/ci.yml calling PowerShellOrg/.github/.github/workflows/powershell-ci.yml@main, which runs ./build.ps1 -Task Test -Bootstrap across Windows PowerShell 5.1, Windows PowerShell 7, Linux PowerShell 7, and macOS PowerShell 7, plus changelog/spell/PSScriptAnalyzer lint checks. pull_request trigger has no branch filter (rather than main-only) so CI runs on every PR in this stack, including intermediate PRs whose base is a feature branch rather than main. Depends on the earlier lowercase tests/ rename in this stack so the reusable workflow's ./tests/out/testResults.xml artifact path resolves on the case-sensitive Linux runner. CI on this PR: Linux/macOS/Windows(PS7) pass. Windows PowerShell 5.1 and the changelog-lint step fail on pre-existing issues this workflow is the first to catch -- tracked as #498 and #499. Refs #488 (do not auto-close; blocked on #498 and #499 for full green CI across all 4 required environments)
1ea60f7 to
a448fed
Compare
Mirrors PSDepend's org-standard workflow set: - publish.yml: calls PowerShellOrg/.github/.github/workflows/powershell-release.yml@main on push to main (and manual dispatch with version/force/dry_run/ create_release/publish overrides) to tag, release, and publish to PSGallery. - stale.yml: daily actions/stale@v9 sweep for inactive issues/PRs, same thresholds and labels as PSDepend.
Stacked on #496 (and #495).
Adds
.github/workflows/ci.ymlcallingPowerShellOrg/.github/.github/workflows/powershell-ci.yml@main, which runs./build.ps1 -Task Test -Bootstrapacross Windows PowerShell 5.1, Windows PowerShell 7, Linux PowerShell 7, and macOS PowerShell 7, plus changelog/spell/PSScriptAnalyzer lint checks.Also adds two more org-standard reusable workflows (mirrored from PSDepend):
.github/workflows/publish.yml-- callspowershell-release.yml@mainon push tomain(plus manual dispatch overrides) to tag, release, and publish to PSGallery..github/workflows/stale.yml-- dailyactions/stale@v9sweep for inactive issues/PRs.Depends on the
tests/lowercase rename in #496 so the reusable workflow's./tests/out/testResults.xmlartifact path resolves on the case-sensitive Linux runner.CI status on this PR: Linux/macOS/Windows (PS7) legs pass. Windows PowerShell 5.1 and the changelog-lint step fail on pre-existing issues this workflow is the first to catch (legacy CI never ran PS5.1 or linted CHANGELOG.md) -- tracked separately as #498 and #499.
Refs #488 -- do not close automatically; #488''s "CI is green on all 4 environments" criterion isn''t met until #498 and #499 land.
Stack: #495 -> #496 -> 3/3