Skip to content

Commit caaee7a

Browse files
authored
Update all files to use {% data %} (github#15253)
* Add back changes from prior to purge * Manually fix some invalid Liquid * Updoot render-content * Improve test messages to show correct output * Run el scripto * Pass the remaining test
1 parent aa5a62d commit caaee7a

File tree

14,816 files changed

+100352
-100282
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

14,816 files changed

+100352
-100282
lines changed

content/actions/creating-actions/about-actions.md

+21-21
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: About actions
3-
intro: 'Actions are individual tasks that you can combine to create jobs and customize your workflow. You can create your own actions, or use and customize actions shared by the {{ site.data.variables.product.prodname_dotcom }} community.'
4-
product: '{{ site.data.reusables.gated-features.actions }}'
3+
intro: 'Actions are individual tasks that you can combine to create jobs and customize your workflow. You can create your own actions, or use and customize actions shared by the {% data variables.product.prodname_dotcom %} community.'
4+
product: '{% data reusables.gated-features.actions %}'
55
redirect_from:
66
- /articles/about-actions
77
- /github/automating-your-workflow-with-github-actions/about-actions
@@ -12,22 +12,22 @@ versions:
1212
enterprise-server: '>=2.22'
1313
---
1414

15-
{{ site.data.reusables.actions.enterprise-beta }}
16-
{{ site.data.reusables.actions.enterprise-github-hosted-runners }}
15+
{% data reusables.actions.enterprise-beta %}
16+
{% data reusables.actions.enterprise-github-hosted-runners %}
1717

1818
### About actions
1919

20-
You can create actions by writing custom code that interacts with your repository in any way you'd like, including integrating with {{ site.data.variables.product.prodname_dotcom }}'s APIs and any publicly available third-party API. For example, an action can publish npm modules, send SMS alerts when urgent issues are created, or deploy production-ready code.
20+
You can create actions by writing custom code that interacts with your repository in any way you'd like, including integrating with {% data variables.product.prodname_dotcom %}'s APIs and any publicly available third-party API. For example, an action can publish npm modules, send SMS alerts when urgent issues are created, or deploy production-ready code.
2121

2222
{% if currentVersion == "free-pro-team@latest" %}
23-
You can write your own actions to use in your workflow or share the actions you build with the {{ site.data.variables.product.prodname_dotcom }} community. To share actions you've built, your repository must be public.
23+
You can write your own actions to use in your workflow or share the actions you build with the {% data variables.product.prodname_dotcom %} community. To share actions you've built, your repository must be public.
2424
{% endif %}
2525

2626
Actions can run directly on a machine or in a Docker container. You can define an action's inputs, outputs, and environment variables.
2727

2828
### Types of actions
2929

30-
You can build Docker container and JavaScript 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 "[Metadata syntax for {{ site.data.variables.product.prodname_actions }}](/articles/metadata-syntax-for-github-actions)."
30+
You can build Docker container and JavaScript 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 "[Metadata syntax for {% data variables.product.prodname_actions %}](/articles/metadata-syntax-for-github-actions)."
3131

3232
| Type | Operating system |
3333
| ---- | ------------------- |
@@ -37,19 +37,19 @@ You can build Docker container and JavaScript actions. Actions require a metadat
3737

3838
#### Docker container actions
3939

40-
Docker containers package the environment with the {{ site.data.variables.product.prodname_actions }} code. This creates a more consistent and reliable unit of work because the consumer of the action does not need to worry about the tools or dependencies.
40+
Docker containers package the environment with the {% data variables.product.prodname_actions %} code. This creates a more consistent and reliable unit of work because the consumer of the action does not need to worry about the tools or dependencies.
4141

4242
A Docker container allows you to use specific versions of an operating system, dependencies, tools, and code. For actions that must run in a specific environment configuration, Docker is an ideal option because you can customize the operating system and tools. Because of the latency to build and retrieve the container, Docker container actions are slower than JavaScript actions.
4343

44-
Docker container actions can only execute on runners with a Linux operating system. {{ site.data.reusables.github-actions.self-hosted-runner-reqs-docker }}
44+
Docker container actions can only execute on runners with a Linux operating system. {% data reusables.github-actions.self-hosted-runner-reqs-docker %}
4545

4646
#### JavaScript actions
4747

4848
JavaScript actions can run directly on a runner machine, and separate the action code from the environment used to run the code. Using a JavaScript action simplifies the action code and executes faster than a Docker container action.
4949

50-
{{ site.data.reusables.github-actions.pure-javascript }}
50+
{% data reusables.github-actions.pure-javascript %}
5151

52-
If you're developing a Node.js project, the {{ site.data.variables.product.prodname_actions }} Toolkit provides packages that you can use in your project to speed up development. For more information, see the [actions/toolkit](https://github.com/actions/toolkit) repository.
52+
If you're developing a Node.js project, the {% data variables.product.prodname_actions %} Toolkit provides packages that you can use in your project to speed up development. For more information, see the [actions/toolkit](https://github.com/actions/toolkit) repository.
5353

5454
#### Composite run steps actions
5555

@@ -60,14 +60,14 @@ A _composite run steps_ action allows you to combine multiple workflow run steps
6060
If you're developing an action for other people to use, we recommend keeping the action in its own repository instead of bundling it with other application code. This allows you to version, track, and release the action just like any other software.
6161

6262
{% if currentVersion == "free-pro-team@latest" %}
63-
Storing an action in its own repository makes it easier for the {{ site.data.variables.product.prodname_dotcom }} community to discover the action, narrows the scope of the code base for developers fixing issues and extending the action, and decouples the action's versioning from the versioning of other application code.
63+
Storing an action in its own repository makes it easier for the {% data variables.product.prodname_dotcom %} community to discover the action, narrows the scope of the code base for developers fixing issues and extending the action, and decouples the action's versioning from the versioning of other application code.
6464
{% endif %}
6565

6666
{% if currentVersion == "free-pro-team@latest" %}If you're building an action that you don't plan to make available to the public, you {% else %} You{% endif %} can store the action's files in any location in your repository. If you plan to combine action, workflow, and application code in a single repository, we recommend storing actions in the `.github` directory. For example, `.github/actions/action-a` and `.github/actions/action-b`.
6767

68-
### Compatibility with {{ site.data.variables.product.prodname_ghe_server }}
68+
### Compatibility with {% data variables.product.prodname_ghe_server %}
6969

70-
To ensure that your action is compatible with {{ site.data.variables.product.prodname_ghe_server }}, you should make sure that you do not use any hard-coded references to {{ site.data.variables.product.prodname_dotcom }} API URLs. You should instead use environment variables to refer to the {{ site.data.variables.product.prodname_dotcom }} API:
70+
To ensure that your action is compatible with {% data variables.product.prodname_ghe_server %}, you should make sure that you do not use any hard-coded references to {% data variables.product.prodname_dotcom %} API URLs. You should instead use environment variables to refer to the {% data variables.product.prodname_dotcom %} API:
7171

7272
- For the REST API, use the `GITHUB_API_URL` environment variable.
7373
- For GraphQL, use the `GITHUB_GRAPHQL_URL` environment variable.
@@ -84,7 +84,7 @@ If you're developing an action for other people to use, we recommend using relea
8484

8585
Under this release management approach, users should not be referencing an action's `master` branch, as it's likely to contain the latest code and consequently might be unstable. Instead, you can recommend that your users specify a major version when using your action, and only direct them to a more specific version if they encounter issues.
8686

87-
To use a specific action version, users can configure their {{ site.data.variables.product.prodname_actions }} workflow to target a tag, a commit's SHA, or a branch named for a release.
87+
To use a specific action version, users can configure their {% data variables.product.prodname_actions %} workflow to target a tag, a commit's SHA, or a branch named for a release.
8888

8989
#### Using tags for release management
9090

@@ -139,21 +139,21 @@ We recommend creating a README file to help people learn how to use your action.
139139
- Environment variables the action uses
140140
- An example of how to use your action in a workflow
141141

142-
### Comparing {{ site.data.variables.product.prodname_actions }} to {{ site.data.variables.product.prodname_github_apps}}
142+
### Comparing {% data variables.product.prodname_actions %} to {% data variables.product.prodname_github_apps %}
143143

144-
{{ site.data.variables.product.prodname_marketplace }} offers tools to improve your workflow. Understanding the differences and the benefits of each tool will allow you to select the best tool for your job. For more information about building apps, see "[About apps](/apps/about-apps/)."
144+
{% data variables.product.prodname_marketplace %} offers tools to improve your workflow. Understanding the differences and the benefits of each tool will allow you to select the best tool for your job. For more information about building apps, see "[About apps](/apps/about-apps/)."
145145

146146
#### Strengths of GitHub Actions and GitHub Apps
147147

148-
While both {{ site.data.variables.product.prodname_actions }} and {{ site.data.variables.product.prodname_github_app }}s provide ways to build automation and workflow tools, they each have strengths that make them useful in different ways.
148+
While both {% data variables.product.prodname_actions %} and {% data variables.product.prodname_github_app %}s provide ways to build automation and workflow tools, they each have strengths that make them useful in different ways.
149149

150-
{{ site.data.variables.product.prodname_github_apps }}:
150+
{% data variables.product.prodname_github_apps %}:
151151
* Run persistently and can react to events quickly.
152152
* Work great when persistent data is needed.
153153
* Work best with API requests that aren't time consuming.
154154
* Run on a server or compute infrastructure that you provide.
155155

156-
{{ site.data.variables.product.prodname_actions }}:
156+
{% data variables.product.prodname_actions %}:
157157
* Provide automation that can perform continuous integration and continuous deployment.
158158
* Can run directly on runner machines or in Docker containers.
159159
* Can include access to a clone of your repository, enabling deployment and publishing tools, code formatters, and command line tools to access your code.
@@ -162,4 +162,4 @@ While both {{ site.data.variables.product.prodname_actions }} and {{ site.data.v
162162

163163
### Further reading
164164

165-
- "[Development tools for {{ site.data.variables.product.prodname_actions }}](/articles/development-tools-for-github-actions)"
165+
- "[Development tools for {% data variables.product.prodname_actions %}](/articles/development-tools-for-github-actions)"

content/actions/creating-actions/creating-a-composite-run-steps-action.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
---
22
title: Creating a composite run steps action
33
intro: 'In this guide, you''ll learn how to build a composite run steps action.'
4-
product: '{{ site.data.reusables.gated-features.actions }}'
4+
product: '{% data reusables.gated-features.actions %}'
55
versions:
66
free-pro-team: '*'
77
enterprise-server: '>=2.22'
88
---
99

10-
{{ site.data.reusables.actions.enterprise-beta }}
11-
{{ site.data.reusables.actions.enterprise-github-hosted-runners }}
10+
{% data reusables.actions.enterprise-beta %}
11+
{% data reusables.actions.enterprise-github-hosted-runners %}
1212

1313
### Introduction
1414

@@ -18,9 +18,9 @@ Once you complete this project, you should understand how to build your own comp
1818

1919
### Prerequisites
2020

21-
Before you begin, you'll create a {{ site.data.variables.product.product_name }} repository.
21+
Before you begin, you'll create a {% data variables.product.product_name %} repository.
2222

23-
1. Create a new public repository on {{ site.data.variables.product.product_location }}. You can choose any repository name, or use the following `hello-world-composite-run-steps-action` example. You can add these files after your project has been pushed to {{ site.data.variables.product.product_name }}. For more information, see "[Create a new repository](/articles/creating-a-new-repository)."
23+
1. Create a new public repository on {% data variables.product.product_location %}. You can choose any repository name, or use the following `hello-world-composite-run-steps-action` example. You can add these files after your project has been pushed to {% data variables.product.product_name %}. For more information, see "[Create a new repository](/articles/creating-a-new-repository)."
2424

2525
1. Clone your repository to your computer. For more information, see "[Cloning a repository](/articles/cloning-a-repository)."
2626

content/actions/creating-actions/creating-a-docker-container-action.md

+13-13
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: Creating a Docker container action
33
intro: 'This guide shows you the minimal steps required to build a Docker container action. '
4-
product: '{{ site.data.reusables.gated-features.actions }}'
4+
product: '{% data reusables.gated-features.actions %}'
55
redirect_from:
66
- /articles/creating-a-docker-container-action
77
- /github/automating-your-workflow-with-github-actions/creating-a-docker-container-action
@@ -12,27 +12,27 @@ versions:
1212
enterprise-server: '>=2.22'
1313
---
1414

15-
{{ site.data.reusables.actions.enterprise-beta }}
16-
{{ site.data.reusables.actions.enterprise-github-hosted-runners }}
15+
{% data reusables.actions.enterprise-beta %}
16+
{% data reusables.actions.enterprise-github-hosted-runners %}
1717

1818
### Introduction
1919

2020
In this guide, you'll learn about the basic components needed to create and use a packaged Docker container action. To focus this guide on the components needed to package the action, the functionality of the action's code is minimal. The action prints "Hello World" in the logs or "Hello [who-to-greet]" if you provide a custom name.
2121

2222
Once you complete this project, you should understand how to build your own Docker container action and test it in a workflow.
2323

24-
{{ site.data.reusables.github-actions.self-hosted-runner-reqs-docker }}
24+
{% data reusables.github-actions.self-hosted-runner-reqs-docker %}
2525

2626
### Prerequisites
2727

28-
You may find it helpful to have a basic understanding of {{ site.data.variables.product.prodname_actions }} environment variables and the Docker container filesystem:
28+
You may find it helpful to have a basic understanding of {% data variables.product.prodname_actions %} environment variables and the Docker container filesystem:
2929

3030
- "[Using environment variables](/actions/automating-your-workflow-with-github-actions/using-environment-variables)"
31-
- "[Virtual environments for {{ site.data.variables.product.prodname_dotcom }}](/actions/automating-your-workflow-with-github-actions/virtual-environments-for-github-hosted-runners#docker-container-filesystem)"
31+
- "[Virtual environments for {% data variables.product.prodname_dotcom %}](/actions/automating-your-workflow-with-github-actions/virtual-environments-for-github-hosted-runners#docker-container-filesystem)"
3232

3333
Before you begin, you'll need to create a GitHub repository.
3434

35-
1. Create a new repository on {{ site.data.variables.product.product_location }}. You can choose any repository name or use "hello-world-docker-action" like this example. For more information, see "[Create a new repository](/articles/creating-a-new-repository)."
35+
1. Create a new repository on {% data variables.product.product_location %}. You can choose any repository name or use "hello-world-docker-action" like this example. For more information, see "[Create a new repository](/articles/creating-a-new-repository)."
3636

3737
1. Clone your repository to your computer. For more information, see "[Cloning a repository](/articles/cloning-a-repository)."
3838

@@ -44,7 +44,7 @@ Before you begin, you'll need to create a GitHub repository.
4444

4545
### Creating a Dockerfile
4646

47-
In your new `hello-world-docker-action` directory, create a new `Dockerfile` file. For more information, see "[Dockerfile support for {{ site.data.variables.product.prodname_actions }}](/actions/creating-actions/dockerfile-support-for-github-actions)."
47+
In your new `hello-world-docker-action` directory, create a new `Dockerfile` file. For more information, see "[Dockerfile support for {% data variables.product.prodname_actions %}](/actions/creating-actions/dockerfile-support-for-github-actions)."
4848

4949
**Dockerfile**
5050
```dockerfile
@@ -60,7 +60,7 @@ ENTRYPOINT ["/entrypoint.sh"]
6060

6161
### Creating an action metadata file
6262

63-
Create a new `action.yml` file in the `hello-world-docker-action` directory you created above. For more information, see "[Metadata syntax for {{ site.data.variables.product.prodname_actions }}](/actions/creating-actions/metadata-syntax-for-github-actions)."
63+
Create a new `action.yml` file in the `hello-world-docker-action` directory you created above. For more information, see "[Metadata syntax for {% data variables.product.prodname_actions %}](/actions/creating-actions/metadata-syntax-for-github-actions)."
6464

6565
{% raw %}
6666
**action.yml**
@@ -86,13 +86,13 @@ runs:
8686
8787
This metadata defines one `who-to-greet` input and one `time` output parameter. To pass inputs to the Docker container, you must declare the input using `inputs` and pass the input in the `args` keyword.
8888

89-
{{ site.data.variables.product.prodname_dotcom }} will build an image from your `Dockerfile`, and run commands in a new container using this image.
89+
{% data variables.product.prodname_dotcom %} will build an image from your `Dockerfile`, and run commands in a new container using this image.
9090

9191
### Writing the action code
9292

9393
You can choose any base Docker image and, therefore, any language for your action. The following shell script example uses the `who-to-greet` input variable to print "Hello [who-to-greet]" in the log file.
9494

95-
Next, the script gets the current time and sets it as an output variable that actions running later in a job can use. In order for {{ site.data.variables.product.prodname_dotcom }} to recognize output variables, you must use a workflow command in a specific syntax: `echo "::set-output name=<output name>::<value>"`. For more information, see "[Workflow commands for {{ site.data.variables.product.prodname_actions }}](/actions/reference/workflow-commands-for-github-actions#setting-an-output-parameter)."
95+
Next, the script gets the current time and sets it as an output variable that actions running later in a job can use. In order for {% data variables.product.prodname_dotcom %} to recognize output variables, you must use a workflow command in a specific syntax: `echo "::set-output name=<output name>::<value>"`. For more information, see "[Workflow commands for {% data variables.product.prodname_actions %}](/actions/reference/workflow-commands-for-github-actions#setting-an-output-parameter)."
9696

9797
1. Create a new `entrypoint.sh` file in the `hello-world-docker-action` directory.
9898

@@ -153,7 +153,7 @@ with:
153153
who-to-greet: 'Mona the Octocat'
154154
```
155155
156-
### Commit, tag, and push your action to {{ site.data.variables.product.product_name }}
156+
### Commit, tag, and push your action to {% data variables.product.product_name %}
157157
158158
From your terminal, commit your `action.yml`, `entrypoint.sh`, `Dockerfile`, and `README.md` files.
159159

@@ -170,7 +170,7 @@ git push --follow-tags
170170

171171
Now you're ready to test your action out in a workflow. When an action is in a private repository, the action can only be used in workflows in the same repository. Public actions can be used by workflows in any repository.
172172

173-
{{ site.data.reusables.actions.enterprise-marketplace-actions }}
173+
{% data reusables.actions.enterprise-marketplace-actions %}
174174

175175
#### Example using a public action
176176

0 commit comments

Comments
 (0)