Skip to content

Commit 88dffb2

Browse files
authored
repo sync
2 parents 78e71e8 + 4e1d62b commit 88dffb2

File tree

4 files changed

+30
-3
lines changed

4 files changed

+30
-3
lines changed

contributing/content-style-guide.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ These guidelines are specific to GitHub’s documentation. For general style que
1212
- [Code blocks](#code-blocks)
1313
- [Commands](#commands)
1414
- [Examples](#examples)
15+
- [Indentation](#indentation)
1516
- [Headers](#headers)
1617
- [Images](#images)
1718
- [Alt text](#alt-text)
@@ -129,6 +130,21 @@ schedule:
129130
- cron: "40 19 * * *"
130131
```
131132

133+
### Indentation
134+
135+
In YAML examples, such as actions and workflow files, use two spaces to indent lines within nested lists and block sequences.
136+
137+
- **Use:**
138+
139+
```yaml
140+
steps:
141+
- uses: actions/checkout@v2
142+
- name: Setup Python
143+
uses: actions/setup-python@v2
144+
with:
145+
python-version: ${{ matrix.python }}
146+
```
147+
132148
## Headers
133149
134150
Use H3 for headers, and H4 for subheaders. When referring to headers, surround the header name with quotation marks.

lib/page.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ class Page {
6565
// only the homepage will not have this.parentProduct
6666
.filter(availableVersion => this.parentProduct && !this.parentProduct.versions.includes(availableVersion))
6767

68-
if (versionsParentProductIsNotAvailableIn.length && this.languageCode === 'en') {
68+
if (versionsParentProductIsNotAvailableIn.length) {
6969
throw new Error(`\`versions\` frontmatter in ${this.fullPath} contains ${versionsParentProductIsNotAvailableIn}, which ${this.parentProduct.id} product is not available in!`)
7070
}
7171

tests/unit/page.js

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -389,7 +389,7 @@ describe('catches errors thrown in Page class', () => {
389389
expect(getPage).toThrowError('versions')
390390
})
391391

392-
test('page with a version in frontmatter that its parent product is not available in', () => {
392+
test('English page with a version in frontmatter that its parent product is not available in', () => {
393393
function getPage () {
394394
return new Page({
395395
relativePath: 'admin/some-category/some-article-with-mismatched-versions-frontmatter.md',
@@ -400,4 +400,16 @@ describe('catches errors thrown in Page class', () => {
400400

401401
expect(getPage).toThrowError(/`versions` frontmatter.*? product is not available in/)
402402
})
403+
404+
test('non-English page with a version in frontmatter that its parent product is not available in', () => {
405+
function getPage () {
406+
return new Page({
407+
relativePath: 'admin/some-category/some-article-with-mismatched-versions-frontmatter.md',
408+
basePath: path.join(__dirname, '../fixtures/products'),
409+
languageCode: 'es'
410+
})
411+
}
412+
413+
expect(getPage).toThrowError(/`versions` frontmatter.*? product is not available in/)
414+
})
403415
})

translations/es-XL/content/insights/installing-and-configuring-github-insights/updating-github-insights.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ redirect_from:
66
- /github/installing-and-configuring-github-insights/updating-github-insights
77
permissions: 'Las personas con permisos de lectura para el repositorio de `github/insights-releases` y el acceso administrativo al servidor de aplicaciones pueden actualizar {% data variables.product.prodname_insights %}.'
88
versions:
9-
free-pro-team: '*'
109
enterprise-server: '*'
1110
---
1211

0 commit comments

Comments
 (0)