Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

[Feature]: Add ReleaseType input to Publish-PSModule for explicit release control #265

Copy link
Copy link
@MariusStorhaug

Description

Summary

Add a new ReleaseType input parameter to Publish-PSModule action that allows users to explicitly specify the type of release to create, overriding the automatic detection based on PR state and labels.

Motivation

Currently, the release type is automatically determined based on:

  • Whether the PR is merged
  • Whether the target is the default branch
  • Whether the PR has a prerelease label

There are scenarios where users need more control over the release process, such as:

  • Forcing a specific release type in CI/CD pipelines
  • Testing release workflows without relying on label-based detection
  • Integration with other tools that determine release type externally (e.g., Get-PSModuleSettings)

Proposed Solution

Add a ReleaseType input with the following valid values:

  • Release - Create a stable release
  • Prerelease - Create a prerelease
  • Cleanup - Delete old prereleases
  • None - Do not create any release

When set, this input overrides the automatic detection logic.

Implementation

This change affects PSModule/Publish-PSModule:

  • Add ReleaseType input to action.yml
  • Pass environment variable to PowerShell script
  • Update release type calculation to use the input when provided
  • Simplify the event information logging (remove redundant PR state checks)

Related

Reactions are currently unavailable

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.