Skip to content

Commit 38a0652

Browse files
author
Your Name
committed
docs: clarify workflow_dispatch environment input
1 parent fa4d1bc commit 38a0652

2 files changed

Lines changed: 4 additions & 0 deletions

File tree

content/actions/reference/workflows-and-actions/events-that-trigger-workflows.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1081,6 +1081,8 @@ You can configure custom-defined input properties, default input values, and req
10811081

10821082
This example defines inputs called `logLevel`, `tags`, and `environment`. You pass values for these inputs to the workflow when you run it. This workflow then prints the values to the log, using the `inputs.logLevel`, `inputs.tags`, and `inputs.environment` context properties.
10831083

1084+
When you use `type: environment`, GitHub shows the workflow's environment names as the available values for that input.
1085+
10841086
```yaml
10851087
on:
10861088
workflow_dispatch:

content/actions/reference/workflows-and-actions/workflow-syntax.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -265,6 +265,8 @@ A boolean specifying whether the input must be supplied.
265265

266266
The value of this parameter is a string specifying the data type of the input. This must be one of: `boolean`, `choice`, `number`, `environment` or `string`.
267267

268+
The `environment` type is a special case that lets the workflow runner present the repository's available environments as the input choices.
269+
268270
## `permissions`
269271

270272
{% data reusables.actions.jobs.section-assigning-permissions-to-jobs %}

0 commit comments

Comments
 (0)