1
0
mirror of synced 2025-12-19 18:10:59 -05:00

fix incorrect code languages

This commit is contained in:
Rachael Sewell
2023-09-25 11:40:18 -07:00
parent c0a1de57f1
commit ce11747ab0
12 changed files with 17 additions and 15 deletions

View File

@@ -196,7 +196,7 @@ Replaces values in the `string`, with the variable `replaceValueN`. Variables in
{% raw %} {% raw %}
```js ```javascript
format('Hello {0} {1} {2}', 'Mona', 'the', 'Octocat') format('Hello {0} {1} {2}', 'Mona', 'the', 'Octocat')
``` ```
@@ -208,7 +208,7 @@ Returns 'Hello Mona the Octocat'.
{% raw %} {% raw %}
```js ```javascript
format('{{Hello {0} {1} {2}!}}', 'Mona', 'the', 'Octocat') format('{{Hello {0} {1} {2}!}}', 'Mona', 'the', 'Octocat')
``` ```

View File

@@ -324,7 +324,7 @@ puts openssl_key.verify(OpenSSL::Digest::SHA256.new, Base64.decode64(signature),
**Validation sample in JavaScript** **Validation sample in JavaScript**
```js ```javascript
const crypto = require("crypto"); const crypto = require("crypto");
const axios = require("axios"); const axios = require("axios");

View File

@@ -31,7 +31,7 @@ redirect_from:
![Screenshot of the "Marketplace" tab showing the installation code snippet for Terraform.](/assets/images/help/codespaces/feature-installation-code.png) ![Screenshot of the "Marketplace" tab showing the installation code snippet for Terraform.](/assets/images/help/codespaces/feature-installation-code.png)
```JSON ```json
"features": { "features": {
... ...
"ghcr.io/devcontainers/features/terraform:1": {}, "ghcr.io/devcontainers/features/terraform:1": {},
@@ -43,7 +43,7 @@ redirect_from:
![Screenshot of the "Options" section of the "Marketplace" tab, with the "version" and "tflint" properties expanded.](/assets/images/help/codespaces/feature-options.png) ![Screenshot of the "Options" section of the "Marketplace" tab, with the "version" and "tflint" properties expanded.](/assets/images/help/codespaces/feature-options.png)
```JSON ```json
"features": { "features": {
... ...
"ghcr.io/devcontainers/features/terraform:1": { "ghcr.io/devcontainers/features/terraform:1": {

View File

@@ -62,7 +62,7 @@ You should configure your dev container with the tools and customization to give
The following configuration settings for a React template will open the `app.js` file in the user's editor, run `npm start` (defined in a `package.json` file) to start a local server, and forward port `3000` to a preview browser tab in the codespace. The following configuration settings for a React template will open the `app.js` file in the user's editor, run `npm start` (defined in a `package.json` file) to start a local server, and forward port `3000` to a preview browser tab in the codespace.
```JSON ```json
{ {
"postAttachCommand": { "postAttachCommand": {
"server": "npm start" "server": "npm start"

View File

@@ -195,7 +195,8 @@ Directory | Usage
When there are differences between plans, you can use Liquid conditionals to version the two images. When there are differences between plans, you can use Liquid conditionals to version the two images.
```{% raw %} ```markdown
{% raw %}
{% ifversion fpt or ghec %} {% ifversion fpt or ghec %}
![An image of foo bar for GitHub Free, GitHub Pro, GitHub Team, and GitHub Enterprise Cloud](/assets/images/foo/bar.png) ![An image of foo bar for GitHub Free, GitHub Pro, GitHub Team, and GitHub Enterprise Cloud](/assets/images/foo/bar.png)
{% else %} {% else %}
@@ -209,7 +210,8 @@ If an image will change for {% data variables.product.prodname_ghe_server %} 3.1
Your Liquid conditional would look like this: Your Liquid conditional would look like this:
```{% raw %} ```markdown
{% raw %}
{% ifversion fpt or ghec %} {% ifversion fpt or ghec %}
![An image of foo bar](/assets/images/foo/bar.png) ![An image of foo bar](/assets/images/foo/bar.png)
{% elsif ghes < 3.10 %} {% elsif ghes < 3.10 %}

View File

@@ -50,7 +50,7 @@ When referencing the URL of a label in Markdown, the label is automatically rend
The URL of a label can be found by navigating to the labels page and clicking on a label. For example, the URL of the label "enhancement" in our public [docs repository](https://github.com/github/docs/) is The URL of a label can be found by navigating to the labels page and clicking on a label. For example, the URL of the label "enhancement" in our public [docs repository](https://github.com/github/docs/) is
```md ```markdown
https://github.com/github/docs/labels/enhancement https://github.com/github/docs/labels/enhancement
``` ```

View File

@@ -190,7 +190,7 @@ For more information, see [`gh help formatting`](https://cli.github.com/manual/g
1. In the directory you created, add some source code. For example: 1. In the directory you created, add some source code. For example:
```go ```golang
package main package main
import ( import (
"github.com/cli/go-gh" "github.com/cli/go-gh"

View File

@@ -72,7 +72,7 @@ If you are using C#, you can encrypt your secret using the Sodium.Core package.
In the following example, replace `YOUR_SECRET` with the plain text value that you want to encrypt. Replace `YOUR_BASE64_KEY` with your Base64 encoded public key. The documentation for the endpoint that you will use to create a secret will tell you which endpoint you can use to get the public key. In the following example, replace `YOUR_SECRET` with the plain text value that you want to encrypt. Replace `YOUR_BASE64_KEY` with your Base64 encoded public key. The documentation for the endpoint that you will use to create a secret will tell you which endpoint you can use to get the public key.
```C# copy ```csharp copy
var secretValue = System.Text.Encoding.UTF8.GetBytes("YOUR_SECRET"); var secretValue = System.Text.Encoding.UTF8.GetBytes("YOUR_SECRET");
var publicKey = Convert.FromBase64String("YOUR_BASE64_KEY"); var publicKey = Convert.FromBase64String("YOUR_BASE64_KEY");

View File

@@ -18,7 +18,7 @@ Indented reusables require a special liquid tag: `indented_data_reference` which
For example, to indent `/data/reusables/foo/bar.md` in an ordered list, you could: For example, to indent `/data/reusables/foo/bar.md` in an ordered list, you could:
```md ```markdown
1. My first list item 1. My first list item
{% indented_data_reference reusables.foo.par spaces=2 %} {% indented_data_reference reusables.foo.par spaces=2 %}
1. My second list item 1. My second list item

View File

@@ -4,7 +4,7 @@ In this directory is the main pipeline that converts our content from Liquid, Ma
## Usage ## Usage
```js ```javascript
const renderContent = require('.') const renderContent = require('.')
const html = await renderContent(` const html = await renderContent(`

View File

@@ -28,7 +28,7 @@ In the `handle-redirects.js` middleware, the language part of the URL is
removed, looked up, and if matched to something, redirects with language removed, looked up, and if matched to something, redirects with language
put back in. Demonstrated with pseudo code: put back in. Demonstrated with pseudo code:
```js ```javascript
var fullPath = '/ja/foo' var fullPath = '/ja/foo'
var newPath = redirects['/foo'] var newPath = redirects['/foo']
if (newPath) { if (newPath) {

View File

@@ -108,7 +108,7 @@ Index Name | Description
Each record represents a section of a page. Sections are derived by splitting up pages by their headings. Each record has a `title`, `intro` (if one exists in the frontmatter), `body` content (in text, not HTML), a `url`, and a unique `objectID` that is currently just the permalink of the article. Here's an example: Each record represents a section of a page. Sections are derived by splitting up pages by their headings. Each record has a `title`, `intro` (if one exists in the frontmatter), `body` content (in text, not HTML), a `url`, and a unique `objectID` that is currently just the permalink of the article. Here's an example:
```js ```javascript
{ {
objectID: '/en/actions/creating-actions/about-actions#about-actions', objectID: '/en/actions/creating-actions/about-actions#about-actions',
url: 'https://docs.github.com/en/actions/creating-actions/about-actions#about-actions', url: 'https://docs.github.com/en/actions/creating-actions/about-actions#about-actions',