Skip to content

Commit

Permalink
Add workflow_call event to workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
beagleknight committed Jan 31, 2025
1 parent a1162cf commit 18cba11
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions src/event.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ export type EventName =
| "pull_request_review"
| "workflow_run"
| "workflow_dispatch"
| "workflow_call"
| "schedule"
| "pull_request_target"
| "repository_dispatch";
Expand All @@ -18,6 +19,8 @@ export type EventOptions<T extends EventName> = T extends "push"
? WorkflowRunEventOptions
: T extends "workflow_dispatch"
? WorkflowDispatchEventOptions
: T extends "workflow_call"
? WorkflowCallEventOptions
: T extends "schedule"
? ScheduleEventOptions
: T extends "repository_dispatch"
Expand Down Expand Up @@ -77,6 +80,16 @@ interface WorkflowDispatchEventOptions {
inputs?: Record<string, WorkflowDispatchInput>;
}

interface WorkflowCallSecret {
description?: string;
required?: boolean;
}

interface WorkflowCallEventOptions {
inputs?: Record<string, WorkflowDispatchInput>;
secrets?: Record<string, WorkflowCallSecret>;
}

type ScheduleEventOptions = Array<{ cron: string }>;

interface RepositoryDispatchEventOptions {
Expand Down

0 comments on commit 18cba11

Please sign in to comment.