Skip to content

Conversation

@MariusStorhaug
Copy link
Member

@MariusStorhaug MariusStorhaug commented Jan 17, 2026

Your pull request title and description can now be used as release notes when publishing modules, giving you direct control over how your releases appear to users. Additionally, this PR updates the workflow to pass the computed ReleaseType from Get-PSModuleSettings to Publish-PSModule.

New configuration settings

Three new settings are available in your .github/PSModule.yml file under Publish.Module:

Setting Default Description
UsePRTitleAsReleaseName false Use the PR title as the GitHub release name instead of version string
UsePRBodyAsReleaseNotes true Use the PR description as the release notes content
UsePRTitleAsNotesHeading true Prepend PR title as H1 heading with PR number link in release notes

Default behavior

With the default settings, when you merge a PR, the GitHub release will automatically include:

  • A heading with your PR title and a link to the PR (e.g., # Add retry logic (#123))
  • Your PR description as the release notes body

No configuration changes are needed to benefit from this feature—just write meaningful PR descriptions.

Usage examples

To use all default settings (recommended):

# No configuration needed - defaults work out of the box

To also use the PR title as the release name:

Publish:
  Module:
    UsePRTitleAsReleaseName: true

To disable PR-based release notes entirely (use auto-generated notes):

Publish:
  Module:
    UsePRBodyAsReleaseNotes: false
    UsePRTitleAsNotesHeading: false

Updated workflow references

The workflow now passes ReleaseType from Get-PSModuleSettings to Publish-PSModule, enabling explicit control over the release type. The ReleaseType is computed in Get-PSModuleSettings and stored in Publish.Module.ReleaseType.

@MariusStorhaug MariusStorhaug requested a review from a team as a code owner January 17, 2026 21:06
Copilot AI review requested due to automatic review settings January 17, 2026 21:06
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds three new configurable settings for release notes generation based on pull request metadata, aligning with the Auto-Release pattern. The changes enable users to customize whether the PR title is used as the release name, whether the PR body becomes the release notes content, and whether the PR title appears as a heading above the body.

Changes:

  • Added three new boolean settings to the Publish.Module configuration section
  • Updated the workflow to pass these settings to the Publish-PSModule action
  • Documented the new settings in the README configuration table and defaults example

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
README.md Adds documentation for three new Publish.Module settings (UsePRTitleAsReleaseName, UsePRBodyAsReleaseNotes, UsePRTitleAsNotesHeading) in both the configuration table and defaults YAML example
.github/workflows/Publish-Module.yml Passes the three new settings from the configuration to the Publish-PSModule action

@MariusStorhaug MariusStorhaug changed the title Add PR-based release notes configuration 🚀 [Feature]: Add PR-based release notes configuration Jan 17, 2026
@MariusStorhaug MariusStorhaug changed the title 🚀 [Feature]: Add PR-based release notes configuration 🚀 [Feature]: Add PR Title and Description as Configurable Release Notes Jan 17, 2026
@MariusStorhaug MariusStorhaug marked this pull request as draft January 17, 2026 22:11
@MariusStorhaug MariusStorhaug marked this pull request as ready for review January 17, 2026 22:12
Copilot AI review requested due to automatic review settings January 17, 2026 22:12
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

Copilot AI review requested due to automatic review settings January 17, 2026 23:56
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

Copilot AI review requested due to automatic review settings January 18, 2026 02:28
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 4 comments.

Copilot AI review requested due to automatic review settings January 18, 2026 02:43
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated no new comments.

Copilot AI review requested due to automatic review settings January 18, 2026 10:05
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 4 comments.

Comment on lines +637 to +639
```
#### Auto-generated notes
Copy link

Copilot AI Jan 18, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

According to the Markdown style guidelines (CodingGuidelineID: 1000002), code fence blocks should always be followed by a blank line before continuing with regular text. Add a blank line after the closing code fence and before "#### Auto-generated notes".

Copilot generated this review using guidance from repository custom instructions.
Comment on lines 366 to 409
| Name | Type | Description | Default |
| ----------------------------------------- | --------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------- |
| `Name` | `String` | Name of the module to publish. Defaults to the repository name. | `null` |
| `Test.Skip` | `Boolean` | Skip all tests | `false` |
| `Test.Linux.Skip` | `Boolean` | Skip tests on Linux | `false` |
| `Test.MacOS.Skip` | `Boolean` | Skip tests on macOS | `false` |
| `Test.Windows.Skip` | `Boolean` | Skip tests on Windows | `false` |
| `Test.SourceCode.Skip` | `Boolean` | Skip source code tests | `false` |
| `Test.SourceCode.Linux.Skip` | `Boolean` | Skip source code tests on Linux | `false` |
| `Test.SourceCode.MacOS.Skip` | `Boolean` | Skip source code tests on macOS | `false` |
| `Test.SourceCode.Windows.Skip` | `Boolean` | Skip source code tests on Windows | `false` |
| `Test.PSModule.Skip` | `Boolean` | Skip PSModule framework tests | `false` |
| `Test.PSModule.Linux.Skip` | `Boolean` | Skip PSModule framework tests on Linux | `false` |
| `Test.PSModule.MacOS.Skip` | `Boolean` | Skip PSModule framework tests on macOS | `false` |
| `Test.PSModule.Windows.Skip` | `Boolean` | Skip PSModule framework tests on Windows | `false` |
| `Test.Module.Skip` | `Boolean` | Skip module tests | `false` |
| `Test.Module.Linux.Skip` | `Boolean` | Skip module tests on Linux | `false` |
| `Test.Module.MacOS.Skip` | `Boolean` | Skip module tests on macOS | `false` |
| `Test.Module.Windows.Skip` | `Boolean` | Skip module tests on Windows | `false` |
| `Test.TestResults.Skip` | `Boolean` | Skip test result processing | `false` |
| `Test.CodeCoverage.Skip` | `Boolean` | Skip code coverage tests | `false` |
| `Test.CodeCoverage.PercentTarget` | `Integer` | Target code coverage percentage | `0` |
| `Test.CodeCoverage.StepSummaryMode` | `String` | Step summary mode for code coverage reports | `'Missed, Files'` |
| `Build.Skip` | `Boolean` | Skip all build tasks | `false` |
| `Build.Module.Skip` | `Boolean` | Skip module build | `false` |
| `Build.Docs.Skip` | `Boolean` | Skip documentation build | `false` |
| `Build.Docs.ShowSummaryOnSuccess` | `Boolean` | Show super-linter summary on success for documentation linting | `false` |
| `Build.Site.Skip` | `Boolean` | Skip site build | `false` |
| `Publish.Module.Skip` | `Boolean` | Skip module publishing | `false` |
| `Publish.Module.CleanupPrereleases` | `Boolean` | Automatically clean up old prerelease tags when merging to main or when a PR is abandoned | `true` |
| `Publish.Module.AutoPatching` | `Boolean` | Automatically patch module version | `true` |
| `Publish.Module.IncrementalPrerelease` | `Boolean` | Use incremental prerelease versioning | `true` |
| `Publish.Module.DatePrereleaseFormat` | `String` | Format for date-based prerelease (uses [.NET DateTime format strings](https://learn.microsoft.com/dotnet/standard/base-types/standard-date-and-time-format-strings)) | `''` |
| `Publish.Module.VersionPrefix` | `String` | Prefix for version tags | `'v'` |
| `Publish.Module.MajorLabels` | `String` | Labels indicating a major version bump | `'major, breaking'` |
| `Publish.Module.MinorLabels` | `String` | Labels indicating a minor version bump | `'minor, feature'` |
| `Publish.Module.PatchLabels` | `String` | Labels indicating a patch version bump | `'patch, fix'` |
| `Publish.Module.IgnoreLabels` | `String` | Labels indicating no release | `'NoRelease'` |
| `Publish.Module.UsePRTitleAsReleaseName` | `Boolean` | Use the PR title as the GitHub release name instead of version string | `false` |
| `Publish.Module.UsePRBodyAsReleaseNotes` | `Boolean` | Use the PR body as the release notes content | `true` |
| `Publish.Module.UsePRTitleAsNotesHeading` | `Boolean` | Prepend PR title as H1 heading with PR number link before the body | `true` |
| `Linter.Skip` | `Boolean` | Skip repository linting | `false` |
| `Linter.ShowSummaryOnSuccess` | `Boolean` | Show super-linter summary on success for repository linting | `false` |
| `Linter.env` | `Object` | Environment variables for super-linter configuration | `{}` |
Copy link

Copilot AI Jan 18, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The PR description mentions that the workflow now uses Publish.Module.ReleaseType, and this setting is passed to the Publish-PSModule action on line 56. However, this setting is not documented in the configuration table (lines 366-409) or in the default configuration example. The ReleaseType setting should be added to the documentation to maintain completeness.

Copilot uses AI. Check for mistakes.
Comment on lines +593 to +597
| Parameter | Description |
|-----------|-------------|
| `UsePRTitleAsReleaseName` | Use the PR title as the GitHub release name instead of the version string |
| `UsePRBodyAsReleaseNotes` | Use the PR body as the release notes content |
| `UsePRTitleAsNotesHeading` | Prepend PR title as H1 heading with PR number link before the body |
Copy link

Copilot AI Jan 18, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The documentation table uses regular hyphens in the parameter names which can cause line breaks within the parameter names. According to the Markdown style guidelines (CodingGuidelineID: 1000002), these should use non-breaking hyphens. Replace regular hyphens with non-breaking hyphens for UsePRTitleAsReleaseName, UsePRBodyAsReleaseNotes, and UsePRTitleAsNotesHeading.

Copilot generated this review using guidance from repository custom instructions.
Comment on lines +615 to +617
```

This produces release notes like:
Copy link

Copilot AI Jan 18, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

According to the Markdown style guidelines (CodingGuidelineID: 1000002), code fence blocks should always be followed by a blank line before continuing with regular text. Add a blank line after the closing code fence and before "This produces release notes like:".

Copilot generated this review using guidance from repository custom instructions.
… updating PSResourceGet in Publish-Module workflow
Copilot AI review requested due to automatic review settings January 18, 2026 12:01
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.

- name: Publish module
uses: PSModule/Publish-PSModule@6c25d139fe51b890f75c057897bd58ac344b192a # v2.0.8
uses: PSModule/Publish-PSModule@feature/releasetype-input
Copy link

Copilot AI Jan 18, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The workflow is referencing a feature branch instead of a stable release tag. Using branch references (like @feature/releasetype-input) in production workflows creates instability as the branch content can change unexpectedly. Consider using a specific commit SHA or version tag once the feature is merged and released.

Suggested change
uses: PSModule/Publish-PSModule@feature/releasetype-input
uses: PSModule/Publish-PSModule@v1

Copilot uses AI. Check for mistakes.

- name: Get-Settings
uses: PSModule/Get-PSModuleSettings@5be814463ddf37293196c5bd07c861f6fb617a59 # v1.0.3
uses: PSModule/Get-PSModuleSettings@cleanup
Copy link

Copilot AI Jan 18, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The workflow is referencing a cleanup branch instead of a stable release tag. Using branch references (like @cleanup) in production workflows creates instability as the branch content can change unexpectedly. Consider using a specific commit SHA or version tag once the feature is merged and released.

Suggested change
uses: PSModule/Get-PSModuleSettings@cleanup
uses: PSModule/Get-PSModuleSettings@v1

Copilot uses AI. Check for mistakes.
AutoPatching: ${{ fromJson(inputs.Settings).Publish.Module.AutoPatching }}
DatePrereleaseFormat: ${{ fromJson(inputs.Settings).Publish.Module.DatePrereleaseFormat }}
IgnoreLabels: ${{ fromJson(inputs.Settings).Publish.Module.IgnoreLabels }}
ReleaseType: ${{ fromJson(inputs.Settings).Publish.Module.ReleaseType }}
Copy link

Copilot AI Jan 18, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The new Publish.Module.ReleaseType setting is being passed to the Publish-PSModule action but is not documented in the configuration settings table or in the default settings example. According to the PR description, this setting moved from Run.ReleaseType to Publish.Module.ReleaseType, but users need to know what values this setting accepts and what its purpose is.

Copilot uses AI. Check for mistakes.
Copilot AI review requested due to automatic review settings January 18, 2026 13:54
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.

- name: Publish module
uses: PSModule/Publish-PSModule@6c25d139fe51b890f75c057897bd58ac344b192a # v2.0.8
uses: PSModule/Publish-PSModule@feature/releasetype-input
Copy link

Copilot AI Jan 18, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The removal of the "Download module artifact" and "Update Microsoft.PowerShell.PSResourceGet" steps suggests these are now handled internally by the new action version. However, this creates a dependency on the feature branch implementation. If the action doesn't handle artifact download internally, the publish step will fail. Consider verifying that the referenced action version (feature/releasetype-input) properly handles module artifact retrieval, or document this dependency change in the PR description.

Suggested change
uses: PSModule/Publish-PSModule@feature/releasetype-input
uses: PSModule/Publish-PSModule@v1

Copilot uses AI. Check for mistakes.
Copilot AI review requested due to automatic review settings January 18, 2026 14:09
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated no new comments.

Comments suppressed due to low confidence (1)

.github/workflows/Publish-Module.yml:38

  • The artifact download and PSResourceGet update steps have been removed, but the workflow still references ModulePath: outputs/module on line 38. Without downloading the module artifact first, the outputs/module directory will not exist, causing the publish step to fail. These removed steps appear necessary for the workflow to function correctly.
      - name: Publish module
        uses: PSModule/Publish-PSModule@feature/releasetype-input
        env:
          GH_TOKEN: ${{ github.token }}
        with:
          Name: ${{ fromJson(inputs.Settings).Name }}
          ModulePath: outputs/module

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

2 participants