Skip to content

Commit b65fd9a

Browse files
feat: consolidate CI/CD workflows into a single configuration file and remove obsolete CHANGELOG
1 parent 81efd45 commit b65fd9a

File tree

4 files changed

+3
-134
lines changed

4 files changed

+3
-134
lines changed
Lines changed: 2 additions & 72 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Process-PSModule
1+
name: Process-PSModule - CI
22

33
on:
44
workflow_call:
@@ -63,16 +63,10 @@ on:
6363
required: false
6464
default: '.'
6565

66-
concurrency:
67-
group: ${{ github.workflow }}-${{ github.ref }}
68-
cancel-in-progress: ${{ github.ref != format('refs/heads/{0}', github.event.repository.default_branch) }}
69-
7066
permissions:
71-
contents: write # to checkout the repo and create releases on the repo
67+
contents: read # to checkout the repository
7268
pull-requests: write # to write comments to PRs
7369
statuses: write # to update the status of the workflow from linter
74-
pages: write # to deploy to Pages
75-
id-token: write # to verify the deployment originates from an appropriate source
7670

7771
jobs:
7872
Get-Settings:
@@ -328,67 +322,3 @@ jobs:
328322
Prerelease: ${{ inputs.Prerelease }}
329323
Verbose: ${{ inputs.Verbose }}
330324
Version: ${{ inputs.Version }}
331-
332-
Publish-Site:
333-
if: ${{ needs.Get-TestResults.result == 'success' && needs.Get-CodeCoverage.result == 'success' && needs.Build-Site.result == 'success' && !cancelled() && github.event_name == 'pull_request' && github.event.pull_request.merged == true }}
334-
needs:
335-
- Get-Settings
336-
- Get-TestResults
337-
- Get-CodeCoverage
338-
- Build-Site
339-
permissions:
340-
pages: write # to deploy to Pages
341-
id-token: write # to verify the deployment originates from an appropriate source
342-
environment:
343-
name: github-pages
344-
url: ${{ steps.deployment.outputs.page_url }}
345-
runs-on: ubuntu-latest
346-
steps:
347-
- uses: actions/configure-pages@v5
348-
349-
- name: Deploy to GitHub Pages
350-
id: deployment
351-
uses: actions/deploy-pages@v4
352-
353-
Publish-Module:
354-
if: ${{ needs.Get-Settings.result == 'success' && needs.Get-TestResults.result == 'success' && needs.Get-CodeCoverage.result == 'success' && needs.Build-Site.result == 'success' && !cancelled() && github.event_name == 'pull_request' && github.event.pull_request.merged == true }}
355-
needs:
356-
- Get-Settings
357-
- Get-TestResults
358-
- Get-CodeCoverage
359-
- Build-Site
360-
runs-on: ubuntu-latest
361-
steps:
362-
- name: Checkout Code
363-
uses: actions/checkout@v5
364-
365-
- name: Download module artifact
366-
uses: actions/download-artifact@v5
367-
with:
368-
name: module
369-
path: ${{ inputs.WorkingDirectory }}/outputs/module
370-
371-
- name: Update Microsoft.PowerShell.PSResourceGet
372-
shell: pwsh
373-
run: |
374-
Install-PSResource -Name Microsoft.PowerShell.PSResourceGet -Repository PSGallery -TrustRepository
375-
376-
- name: Publish module
377-
uses: PSModule/Publish-PSModule@v2
378-
env:
379-
GH_TOKEN: ${{ github.token }}
380-
with:
381-
Name: ${{ fromJson(needs.Get-Settings.outputs.Settings).Name }}
382-
ModulePath: outputs/module
383-
APIKey: ${{ secrets.APIKEY }}
384-
WhatIf: ${{ github.repository == 'PSModule/Process-PSModule' }}
385-
AutoCleanup: ${{ fromJson(needs.Get-Settings.outputs.Settings).Publish.Module.AutoCleanup }}
386-
AutoPatching: ${{ fromJson(needs.Get-Settings.outputs.Settings).Publish.Module.AutoPatching }}
387-
DatePrereleaseFormat: ${{ fromJson(needs.Get-Settings.outputs.Settings).Publish.Module.DatePrereleaseFormat }}
388-
IgnoreLabels: ${{ fromJson(needs.Get-Settings.outputs.Settings).Publish.Module.IgnoreLabels }}
389-
IncrementalPrerelease: ${{ fromJson(needs.Get-Settings.outputs.Settings).Publish.Module.IncrementalPrerelease }}
390-
MajorLabels: ${{ fromJson(needs.Get-Settings.outputs.Settings).Publish.Module.MajorLabels }}
391-
MinorLabels: ${{ fromJson(needs.Get-Settings.outputs.Settings).Publish.Module.MinorLabels }}
392-
PatchLabels: ${{ fromJson(needs.Get-Settings.outputs.Settings).Publish.Module.PatchLabels }}
393-
VersionPrefix: ${{ fromJson(needs.Get-Settings.outputs.Settings).Publish.Module.VersionPrefix }}
394-
WorkingDirectory: ${{ inputs.WorkingDirectory }}

.github/workflows/workflow.yml

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -63,10 +63,6 @@ on:
6363
required: false
6464
default: '.'
6565

66-
concurrency:
67-
group: ${{ github.workflow }}-${{ github.ref }}
68-
cancel-in-progress: ${{ github.ref != format('refs/heads/{0}', github.event.repository.default_branch) }}
69-
7066
permissions:
7167
contents: write # to checkout the repo and create releases on the repo
7268
pull-requests: write # to write comments to PRs
@@ -351,7 +347,7 @@ jobs:
351347
uses: actions/deploy-pages@v4
352348

353349
Publish-Module:
354-
if: ${{ needs.Get-Settings.result == 'success' && needs.Get-TestResults.result == 'success' && needs.Get-CodeCoverage.result == 'success' && needs.Build-Site.result == 'success' && !cancelled() && github.event_name == 'pull_request' && github.event.pull_request.merged == true }}
350+
if: ${{ needs.Get-Settings.result == 'success' && needs.Get-TestResults.result == 'success' && needs.Get-CodeCoverage.result == 'success' && needs.Build-Site.result == 'success' && !cancelled() && github.event_name == 'pull_request' }}
355351
needs:
356352
- Get-Settings
357353
- Get-TestResults

CHANGELOG.md

Lines changed: 0 additions & 38 deletions
This file was deleted.

README.md

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -347,25 +347,6 @@ permissions:
347347

348348
For more info see [Deploy GitHub Pages site](https://github.com/marketplace/actions/deploy-github-pages-site).
349349

350-
## Breaking Changes
351-
352-
### v4.0.0 - Unified CI/CD Workflow (2025-10-02)
353-
354-
**Breaking Change**: The `CI.yml` workflow has been removed and consolidated into the main `workflow.yml` file.
355-
356-
**Impact**: Consuming repositories referencing `CI.yml` directly will need to update their workflow calls.
357-
358-
**Migration Required**: If your repository references `.github/workflows/CI.yml` in any workflow files or documentation, update those references to `.github/workflows/workflow.yml`.
359-
360-
**Migration Guide**: See [docs/unified-workflow-migration.md](./docs/unified-workflow-migration.md) for detailed migration instructions.
361-
362-
**Key Changes**:
363-
- All CI/CD functionality now in single `workflow.yml` file
364-
- Conditional publishing based on PR merge state
365-
- Concurrency groups prevent duplicate workflow runs
366-
- Test execution remains unchanged
367-
- Publishing only occurs when PR is merged
368-
369350
## Specifications and practices
370351

371352
Process-PSModule follows:

0 commit comments

Comments
 (0)