Skip to content

Commit d2f795d

Browse files
jasonslchenam-steadheiskr
authored
[Marketplace] update action docs to state that yml is the preferred format and to describe what happens when changing between yml and yaml formats (#54311)
Co-authored-by: Anne-Marie <[email protected]> Co-authored-by: Kevin Heis <[email protected]>
1 parent f7fd257 commit d2f795d

File tree

4 files changed

+15
-5
lines changed

4 files changed

+15
-5
lines changed

content/actions/sharing-automations/creating-actions/about-custom-actions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ Actions can run directly on a machine or in a Docker container. You can define a
3232

3333
## Types of actions
3434

35-
You can build Docker container, JavaScript, and composite actions. Actions require a metadata file to define the inputs, outputs and main entrypoint for your action. The metadata filename must be either `action.yml` or `action.yaml`. For more information, see [AUTOTITLE](/actions/creating-actions/metadata-syntax-for-github-actions).
35+
You can build Docker container, JavaScript, and composite actions. Actions require a metadata file to define the inputs, outputs and main entrypoint for your action. The metadata filename must be `action.yml`. For more information, see [AUTOTITLE](/actions/creating-actions/metadata-syntax-for-github-actions).
3636

3737
{% rowheaders %}
3838

content/actions/sharing-automations/creating-actions/metadata-syntax-for-github-actions.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ type: reference
1919

2020
## About YAML syntax for {% data variables.product.prodname_actions %}
2121

22-
All actions require a metadata file. The metadata filename must be either `action.yml` or `action.yaml`. The data in the metadata file defines the inputs, outputs, and runs configuration for your action.
22+
All actions require a metadata file. The metadata filename must be either `action.yml` or `action.yaml`. The preferred format is `action.yml`. The data in the metadata file defines the inputs, outputs, and runs configuration for your action.
2323

2424
Action metadata files use YAML syntax. If you're new to YAML, you can read [Learn YAML in five minutes](https://www.codeproject.com/Articles/1214409/Learn-YAML-in-five-minutes).
2525

@@ -771,3 +771,12 @@ Brand icons, and all the following icons, are omitted.
771771
<li>zoom-in</li>
772772
<li>zoom-out</li>
773773
</ul>
774+
775+
{% ifversion fpt or ghec %}
776+
777+
## Changing the metadata file name
778+
779+
While the actions metadata file supports both YAML formats, changing the metadata file name (from `action.yml` to `action.yaml` or vice versa) between releases will affect previous release versions that have been published to {% data variables.product.prodname_marketplace %}. Changing the file name will hide all release versions associated with the previous file name from {% data variables.product.prodname_marketplace %}. Previous release versions will still be accessible to users through the source repository.
780+
781+
When releasing new versions of actions, only versions released after the metadata file name change will have the {% data variables.product.prodname_marketplace %} tag and will show up on {% data variables.product.prodname_marketplace %}
782+
{% endif %}

content/actions/sharing-automations/creating-actions/publishing-actions-in-github-marketplace.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ Actions are published to {% data variables.product.prodname_marketplace %} immed
2626
* The action must be in a public repository.
2727
* Each repository must contain a single action.
2828
* Each repository must _not_ contain any workflow files.
29-
* The action's metadata file (`action.yml` or `action.yaml`) must be in the root directory of the repository.
29+
* The action's metadata file (`action.yml`) must be in the root directory of the repository.
3030
* The `name` in the action's metadata file must be unique.
3131
* The `name` cannot match an existing action name published on {% data variables.product.prodname_marketplace %}.
3232
* The `name` cannot match a user or organization on {% data variables.product.prodname_dotcom %}, unless the user or organization owner is publishing the action. For example, only the {% data variables.product.prodname_dotcom %} organization can publish an action named `github`.
@@ -40,7 +40,8 @@ You can add the action you've created to {% data variables.product.prodname_mark
4040
To draft a new release and publish the action to {% data variables.product.prodname_marketplace %}, follow these instructions:
4141

4242
{% data reusables.repositories.navigate-to-repo %}
43-
1. Navigate to the action metadata file in your repository (`action.yml` or `action.yaml`), and you'll see a banner to publish the action to {% data variables.product.prodname_marketplace %}. Click **Draft a release**.
43+
44+
1. Navigate to the action metadata file in your repository (`action.yml`), and you'll see a banner to publish the action to {% data variables.product.prodname_marketplace %}. Click **Draft a release**.
4445
1. Under "Release Action", select **Publish this Action to the {% data variables.product.prodname_marketplace %}**.
4546

4647
> [!NOTE]

content/actions/writing-workflows/choosing-what-your-workflow-does/using-pre-written-building-blocks-in-your-workflow.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ For more information, see [AUTOTITLE](/actions/creating-actions/about-custom-act
165165

166166
An action often accepts or requires inputs and generates outputs that you can use. For example, an action might require you to specify a path to a file, the name of a label, or other data it will use as part of the action processing.
167167

168-
To see the inputs and outputs of an action, check the `action.yml` or `action.yaml` in the root directory of the repository.
168+
To see the inputs and outputs of an action, check the `action.yml` in the root directory of the repository.
169169

170170
In this example `action.yml`, the `inputs` keyword defines a required input called `file-path`, and includes a default value that will be used if none is specified. The `outputs` keyword defines an output called `results-file`, which tells you where to locate the results.
171171

0 commit comments

Comments
 (0)