Skip to content

Commit e8a7ce2

Browse files
committed
chore: Add missing code fence languages
1 parent 1a2de94 commit e8a7ce2

File tree

37 files changed

+106
-105
lines changed

37 files changed

+106
-105
lines changed

content/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ https://github-images.s3.amazonaws.com/enterprise/2.20/assets/images/help/profil
249249

250250
Sometimes you want to link to a Dotcom-only article in Enterprise content and you don't want the link to be Enterprise-ified. To prevent the transformation, write the link using HTML and add a class of `dotcom-only`. For example:
251251

252-
```
252+
```html
253253
<a href="/github/site-policy/github-terms-of-service" class="dotcom-only">GitHub's Terms of Service</a>
254254
```
255255

content/actions/creating-actions/dockerfile-support-for-github-actions.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,20 +47,21 @@ The Docker `ENTRYPOINT` instruction has a _shell_ form and _exec_ form. The Dock
4747

4848
If you configure your container to use the _exec_ form of the `ENTRYPOINT` instruction, the `args` configured in the action's metadata file won't run in a command shell. If the action's `args` contain an environment variable, the variable will not be substituted. For example, using the following _exec_ format will not print the value stored in `$GITHUB_SHA`, but will instead print `"$GITHUB_SHA"`.
4949

50-
```
50+
```dockerfile
5151
ENTRYPOINT ["echo $GITHUB_SHA"]
5252
```
5353

5454
If you want variable substitution, then either use the _shell_ form or execute a shell directly. For example, using the following _exec_ format, you can execute a shell to print the value stored in the `GITHUB_SHA` environment variable.
5555

56-
```
56+
```dockerfile
5757
ENTRYPOINT ["sh", "-c", "echo $GITHUB_SHA"]
58-
````
58+
```
5959

6060
To supply `args` defined in the action's metadata file to a Docker container that uses the _exec_ form in the `ENTRYPOINT`, we recommend creating a shell script called `entrypoint.sh` that you call from the `ENTRYPOINT` instruction:
6161

6262
##### Example *Dockerfile*
63-
```
63+
64+
``` dockerfile
6465
# Container image that runs your code
6566
FROM debian:9.5-slim
6667

content/actions/creating-actions/setting-exit-codes-for-actions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ For more information, see "[Creating a JavaScript action](/articles/creating-a-j
4040

4141
If you are creating a Docker container action, you can set a failure exit code in your `entrypoint.sh` script. For example:
4242

43-
```
43+
```shell
4444
if <condition> ; then
4545
echo "Game over!"
4646
exit 1

content/actions/guides/building-and-testing-nodejs.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,7 @@ steps:
219219

220220
The example above creates an *.npmrc* file with the following contents:
221221

222-
```
222+
```ini
223223
//registry.npmjs.org/:_authToken=${NODE_AUTH_TOKEN}
224224
@octocat:registry=https://registry.npmjs.org/
225225
always-auth=true

content/actions/guides/caching-dependencies-to-speed-up-workflows.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -123,14 +123,14 @@ A cache key can include any of the contexts, functions, literals, and operators
123123
Using expressions to create a `key` allows you to automatically create a new cache when dependencies have changed. For example, you can create a `key` using an expression that calculates the hash of an npm `package-lock.json` file.
124124

125125
{% raw %}
126-
```
126+
```yaml
127127
npm-${{ hashFiles('package-lock.json') }}
128128
```
129129
{% endraw %}
130130

131131
{% data variables.product.prodname_dotcom %} evaluates the expression `hash "package-lock.json"` to derive the final `key`.
132132

133-
```
133+
```yaml
134134
npm-d5ea0750
135135
```
136136

@@ -143,7 +143,7 @@ You can provide a list of restore keys to use when there is a cache miss on `key
143143
#### Example using multiple restore keys
144144

145145
{% raw %}
146-
```
146+
```yaml
147147
restore-keys: |
148148
npm-foobar-${{ hashFiles('package-lock.json') }}
149149
npm-foobar-
@@ -154,7 +154,7 @@ restore-keys: |
154154
The runner evaluates the expressions, which resolve to these `restore-keys`:
155155

156156
{% raw %}
157-
```
157+
```yaml
158158
restore-keys: |
159159
npm-foobar-d5ea0750
160160
npm-foobar-

content/actions/guides/publishing-nodejs-packages.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ jobs:
7979
8080
In the example above, the `setup-node` action creates an *.npmrc* file on the runner with the following contents:
8181

82-
```
82+
```ini
8383
//registry.npmjs.org/:_authToken=${NODE_AUTH_TOKEN}
8484
registry=https://registry.npmjs.org/
8585
always-auth=true
@@ -122,7 +122,7 @@ jobs:
122122

123123
The `setup-node` action creates an *.npmrc* file on the runner. When you use the `scope` input to the `setup-node` action, the *.npmrc* file includes the scope prefix. By default, the `setup-node` action sets the scope in the *.npmrc* file to the account that contains that workflow file.
124124

125-
```
125+
```ini
126126
//npm.pkg.github.com/:_authToken=${NODE_AUTH_TOKEN}
127127
@octocat:registry=https://npm.pkg.github.com
128128
always-auth=true

content/actions/guides/storing-workflow-data-as-artifacts.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ jobs:
115115
116116
You can define a custom retention period for individual artifacts created by a workflow. When using a workflow to create a new artifact, you can use `retention-days` with the `upload-artifact` action. This example demonstrates how to set a custom retention period of 5 days for the artifact named `my-artifact`:
117117

118-
```
118+
```yaml
119119
- name: 'Upload Artifact'
120120
uses: actions/upload-artifact@v2
121121
with:

content/actions/hosting-your-own-runners/using-a-proxy-server-with-self-hosted-runners.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ If setting environment variables is not practical, you can set the proxy configu
3737

3838
An example _.env_ proxy configuration is shown below:
3939

40-
```
40+
```ini
4141
https_proxy=http://proxy.local:8080
4242
no_proxy=example.com,myserver.local:443
4343
```

content/actions/managing-workflow-runs/adding-a-workflow-status-badge.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,30 +34,30 @@ https://github.com/<OWNER>/<REPOSITORY>/workflows/<WORKFLOW_FILE_PATH>/badge.svg
3434

3535
This Markdown example adds a status badge for a workflow with the name "Greet Everyone." The `OWNER` of the repository is the `actions` organization and the `REPOSITORY` name is `hello-world`.
3636

37-
```
37+
```markdown
3838
![example workflow name](https://github.com/actions/hello-world/workflows/Greet%20Everyone/badge.svg)
3939
```
4040

4141
### Using a workflow file path
4242

4343
This Markdown example adds a status badge for a workflow with the file path `.github/workflows/main.yml`. The `OWNER` of the repository is the `actions` organization and the `REPOSITORY` name is `hello-world`.
4444

45-
```
45+
```markdown
4646
![example workflow file path](https://github.com/actions/hello-world/workflows/.github/workflows/main.yml/badge.svg)
4747
```
4848

4949
### Using the `branch` parameter
5050

5151
This Markdown example adds a status badge for a branch with the name `feature-1`.
5252

53-
```
53+
```markdown
5454
![example branch parameter](https://github.com/actions/hello-world/workflows/Greet%20Everyone/badge.svg?branch=feature-1)
5555
```
5656

5757
### Using the `event` parameter
5858

5959
This Markdown example adds a badge that displays the status of workflow runs triggered by the `pull_request` event.
6060

61-
```
61+
```markdown
6262
![example event parameter](https://github.com/actions/hello-world/workflows/Greet%20Everyone/badge.svg?event=pull_request)
6363
```

content/actions/reference/workflow-commands-for-github-actions.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,7 @@ During the execution of a workflow, the runner generates temporary files that ca
253253

254254
**Warning:** Powershell does not use UTF-8 by default. Make sure you write files using the correct encoding. For example, you need to set UTF-8 encoding when you set the path:
255255

256-
```
256+
```yaml
257257
steps:
258258
- run: echo "mypath" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
259259
```
@@ -287,7 +287,7 @@ For multiline strings, you may use a delimiter with the following syntax.
287287
##### Example
288288
289289
In this example, we use `EOF` as a delimiter and set the `JSON_RESPONSE` environment variable to the value of the curl response.
290-
```
290+
```yaml
291291
steps:
292292
- name: Set the value
293293
id: step_one

0 commit comments

Comments
 (0)