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
This release introduces a new GitHub Action, `Get-PSModuleSettings`,
which replaces the previous template action in
[PSModule/Process-PSModule](https://github.com/PSModule/Process-PSModule).
The action is designed to load and process PowerShell module workflow
settings from configuration files, compute job run conditions, and
output structured settings and test suite information for use in CI
pipelines.
## How It Works
The `Get-PSModuleSettings` action:
1. **Loads settings** from a specified configuration file (supporting
JSON, YAML, or PSD1 formats)
2. **Validates settings** against a comprehensive JSON schema to ensure
correctness
3. **Applies defaults** for any missing configuration values
4. **Generates test suite matrices** for multiple operating systems
(Linux, macOS, Windows) based on test discovery
5. **Computes job run conditions** based on PR state (open, updated,
merged, abandoned)
6. **Outputs structured JSON** containing all settings, test suites, and
run conditions for downstream workflow steps
### Configuration Format Support
The action supports three configuration formats:
- **JSON** - Standard JSON configuration files
- **YAML/YML** - Human-readable YAML format
- **PSD1** - PowerShell Data File format (native PowerShell hashtables)
### Test Suite Generation
The action automatically discovers and categorizes tests into three
types:
- **SourceCode tests** - Static analysis and linting of source code
- **PSModule tests** - Tests for the built PowerShell module
- **Module tests** - Integration and functional tests with test matrices
for each OS
Test discovery supports:
- `*.Configuration.ps1` - Test configuration files
- `*.Container.ps1` - Test container files
- `*.Tests.ps1` - Standard Pester test files
### Job Run Conditions
The action calculates intelligent run conditions for each workflow job
based on:
- Pull request state (open, updated, merged, abandoned)
- Configuration skip flags
- Test suite availability
- Ensures abandoned PRs don't waste CI resources
---------
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
0 commit comments