Skip to content

Commit d9c6de5

Browse files
authored
Merge pull request #6001 from github/repo-sync
repo sync
2 parents 46085ec + 77c0582 commit d9c6de5

3,206 files changed

Lines changed: 4643 additions & 4487 deletions

File tree

Some content is hidden

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

script/i18n/homogenize-frontmatter.js

Lines changed: 22 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -7,34 +7,39 @@
77
//
88
// [end-readme]
99

10-
const { execSync } = require('child_process')
1110
const fs = require('fs')
1211
const path = require('path')
12+
const matter = require('gray-matter')
13+
const walk = require('walk-sync')
1314
const readFileAsync = require('../../lib/readfile-async')
1415
const fm = require('../../lib/frontmatter')
15-
const matter = require('gray-matter')
16+
17+
const translationDir = path.posix.join(__dirname, '../../translations')
18+
const translatedMarkdownFiles = walk(translationDir)
19+
.filter(filename => {
20+
return filename.includes('/content/') &&
21+
filename.endsWith('.md') &&
22+
!filename.endsWith('README.md')
23+
})
24+
.map(filename => `translations/${filename}`)
1625

1726
const extractFrontmatter = async (path) => {
1827
const fileContents = await readFileAsync(path, 'utf8')
1928
return fm(fileContents)
2029
}
2130

22-
// Find all content files that differ from the default branch
23-
// TODO: make sure this will work in an Actions workflow
24-
const cmd = 'git -c diff.renameLimit=10000 diff --name-only origin/main'
25-
const changedFilesRelPaths = execSync(cmd)
26-
.toString()
27-
.split('\n')
28-
.filter(filename => {
29-
return filename.startsWith('translations/') &&
30-
filename.includes('/content/') &&
31-
!filename.endsWith('README.md')
32-
})
33-
34-
changedFilesRelPaths.forEach(async (relPath) => {
35-
const localisedAbsPath = path.join(__dirname, '../..', relPath)
31+
translatedMarkdownFiles.forEach(async (relPath) => {
32+
const localisedAbsPath = path.posix.join(__dirname, '../..', relPath)
3633
// find the corresponding english file by removing the first 2 path segments: /translations/<language code>
37-
const engAbsPath = path.join(__dirname, '../..', relPath.split(path.sep).slice(2).join(path.sep))
34+
const engAbsPath = path.posix.join(__dirname, '../..', relPath.split(path.sep).slice(2).join(path.sep))
35+
36+
if (!fs.existsSync(engAbsPath)) {
37+
// This happens when an English file has been moved or deleted and translations are not in sync.
38+
// It does mean this script will not homogenous those translated files, but the docs site does not
39+
// load translated files that don't correlate to an English file, so those translated files can't break things.
40+
console.log(`English file does not exist: ${engAbsPath}`)
41+
return
42+
}
3843

3944
const localisedFrontmatter = await extractFrontmatter(localisedAbsPath)
4045
if (!localisedFrontmatter) return

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@ redirect_from:
99
- /actions/configuring-and-managing-workflows/caching-dependencies-to-speed-up-workflows
1010
versions:
1111
free-pro-team: '*'
12-
type: 'tutorial'
12+
type: tutorial
1313
topics:
14-
- 'Fluxos de trabalho'
14+
- Workflows
1515
---
1616

1717
{% data reusables.actions.ae-beta %}

translations/pt-BR/content/actions/guides/closing-inactive-issues.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
---
22
title: Fechar problemas inativos
3-
intro: Você pode usar {% data variables.product.prodname_actions %} para comentar ou fechar problemas que ficaram inativos por um determinado período de tempo.
3+
intro: 'Você pode usar {% data variables.product.prodname_actions %} para comentar ou fechar problemas que ficaram inativos por um determinado período de tempo.'
44
product: '{% data reusables.gated-features.actions %}'
55
versions:
66
free-pro-team: '*'
77
enterprise-server: '>=2.22'
88
github-ae: '*'
9-
type: 'tutorial'
9+
type: tutorial
1010
topics:
11-
- 'Fluxos de trabalho'
12-
- 'Gerenciamento de projeto'
11+
- Workflows
12+
- Project management
1313
---
1414

1515
{% data reusables.actions.enterprise-beta %}

translations/pt-BR/content/actions/guides/commenting-on-an-issue-when-a-label-is-added.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
---
22
title: Comentar em um problema quando uma etiqueta é adicionada
3-
intro: Você pode usar {% data variables.product.prodname_actions %} para comentar automaticamente nos problema quando uma etiqueta específica é aplicada.
3+
intro: 'Você pode usar {% data variables.product.prodname_actions %} para comentar automaticamente nos problema quando uma etiqueta específica é aplicada.'
44
product: '{% data reusables.gated-features.actions %}'
55
versions:
66
free-pro-team: '*'
77
enterprise-server: '>=2.22'
88
github-ae: '*'
9-
type: 'tutorial'
9+
type: tutorial
1010
topics:
11-
- 'Fluxos de trabalho'
12-
- 'Gerenciamento de projeto'
11+
- Workflows
12+
- Project management
1313
---
1414

1515
{% data reusables.actions.enterprise-beta %}

translations/pt-BR/content/actions/guides/creating-postgresql-service-containers.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ versions:
1010
free-pro-team: '*'
1111
enterprise-server: '>=2.22'
1212
github-ae: '*'
13-
type: 'tutorial'
13+
type: tutorial
1414
topics:
15-
- 'Contêineres'
16-
- 'Docker'
15+
- Containers
16+
- Docker
1717
---
1818

1919
{% data reusables.actions.enterprise-beta %}

translations/pt-BR/content/actions/guides/creating-redis-service-containers.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ versions:
1010
free-pro-team: '*'
1111
enterprise-server: '>=2.22'
1212
github-ae: '*'
13-
type: 'tutorial'
13+
type: tutorial
1414
topics:
15-
- 'Contêineres'
16-
- 'Docker'
15+
- Containers
16+
- Docker
1717
---
1818

1919
{% data reusables.actions.enterprise-beta %}

translations/pt-BR/content/actions/guides/deploying-to-amazon-elastic-container-service.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@ versions:
66
free-pro-team: '*'
77
enterprise-server: '>=2.22'
88
github-ae: '*'
9-
type: 'tutorial'
9+
type: tutorial
1010
topics:
11-
- 'CD'
12-
- 'Contêineres'
13-
- 'Amazon ECS'
11+
- CD
12+
- Containers
13+
- Amazon ECS
1414
---
1515

1616
{% data reusables.actions.enterprise-beta %}

translations/pt-BR/content/actions/guides/deploying-to-azure-app-service.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@ versions:
66
free-pro-team: '*'
77
enterprise-server: '>=2.22'
88
github-ae: '*'
9-
type: 'tutorial'
9+
type: tutorial
1010
topics:
11-
- 'CD'
12-
- 'Contêineres'
13-
- 'Serviço do aplicativo Azure'
11+
- CD
12+
- Containers
13+
- Azure App Service
1414
---
1515

1616
{% data reusables.actions.enterprise-beta %}

translations/pt-BR/content/actions/guides/deploying-to-google-kubernetes-engine.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@ versions:
66
free-pro-team: '*'
77
enterprise-server: '>=2.22'
88
github-ae: '*'
9-
type: 'tutorial'
9+
type: tutorial
1010
topics:
11-
- 'CD'
12-
- 'Contêineres'
13-
- 'Google Kubernetes Engine'
11+
- CD
12+
- Containers
13+
- Google Kubernetes Engine
1414
---
1515

1616
{% data reusables.actions.enterprise-beta %}

translations/pt-BR/content/actions/guides/index.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,9 @@ includeGuides:
4242
- /actions/guides/building-and-testing-java-with-maven
4343
- /actions/guides/building-and-testing-java-with-gradle
4444
- /actions/guides/building-and-testing-java-with-ant
45+
- /actions/guide/building-and-testing-swift
4546
- /actions/guides/installing-an-apple-certificate-on-macos-runners-for-xcode-development
47+
- /actions/guides/building-and-testing-xamarin-applications
4648
- /actions/guides/publishing-nodejs-packages
4749
- /actions/guides/publishing-java-packages-with-maven
4850
- /actions/guides/publishing-java-packages-with-gradle
@@ -70,6 +72,7 @@ includeGuides:
7072
- /actions/guides/commenting-on-an-issue-when-a-label-is-added
7173
- /actions/guides/moving-assigned-issues-on-project-boards
7274
- /actions/guides/removing-a-label-when-a-card-is-added-to-a-project-board-column
75+
- /actions/guides/managing-github-actions-with-github-cli
7376
---
7477

7578
<!-- {% link_in_list /about-continuous-integration %} -->

0 commit comments

Comments
 (0)