Skip to content

Add plural support in safe-outputs#269

Merged
dsyme merged 1 commit intomainfrom
so10
Sep 1, 2025
Merged

Add plural support in safe-outputs#269
dsyme merged 1 commit intomainfrom
so10

Conversation

@dsyme
Copy link
Copy Markdown
Collaborator

@dsyme dsyme commented Sep 1, 2025

Add Plural Safe-Outputs Support

Adds support for plural forms in safe-outputs configuration to allow creating multiple issues and comments in a single workflow execution.

Key Changes

New Syntax:

  • create-issues (plural) with optional max parameter (default: 10)
  • add-issue-comments (plural) with optional max parameter (default: 10)
  • create-pull-request remains singular-only (max: 1)

Configuration Examples:

safe-outputs:
  create-issues:
    max: 3           # Custom limit
  add-issue-comments: # Uses default max: 10
  create-pull-request: # Always max: 1

Implementation:

Updated Go parser to handle both singular/plural forms with early normalization
Enhanced JavaScript validation to respect config-specified max values
Modified processing scripts to handle arrays of items
Extended JSON schema validation
Full backward compatibility maintained
Testing:

1572 Go tests passing
160 JavaScript tests passing
Comprehensive test coverage for new functionality
All existing workflows continue working unchanged.

@dsyme dsyme merged commit 30d34b7 into main Sep 1, 2025
16 checks passed
@dsyme dsyme deleted the so10 branch September 1, 2025 20:24
@github-actions github-actions bot mentioned this pull request Dec 19, 2025
24 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant