Skip to content

Commit 92740f6

Browse files
committed
chore: Add Prettier for Yaml formatting
Related to github#128 - Prettier to fix indenting/quoting across files - Manually adjust list styles to "-" style - Ignore all translated files from automated formatting - Drop redundant CI env variable
1 parent f84ba23 commit 92740f6

Some content is hidden

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

46 files changed

+2154
-1989
lines changed
+13-14
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,21 @@
11
name: 60 Days Stale Check
22
on:
33
schedule:
4-
- cron: "40 16 * * *" # Run each day at 16:40 UTC / 8:40 PST
4+
- cron: '40 16 * * *' # Run each day at 16:40 UTC / 8:40 PST
55

66
jobs:
77
stale:
88
runs-on: ubuntu-latest
99
steps:
10-
- uses: actions/stale@af4072615903a8b031f986d25b1ae3bf45ec44d4
11-
with:
12-
repo-token: ${{ secrets.GITHUB_TOKEN }}
13-
stale-issue-message: 'This issue is stale because it has been open 60 days with no activity.'
14-
stale-pr-message: 'This PR is stale because it has been open 60 days with no activity.'
15-
days-before-stale: 60
16-
days-before-close: -1
17-
only-labels: 'engineering'
18-
stale-issue-label: 'stale'
19-
stale-pr-label: 'stale'
20-
exempt-pr-labels: 'never-stale'
21-
exempt-issue-labels: 'never-stale'
22-
10+
- uses: actions/stale@af4072615903a8b031f986d25b1ae3bf45ec44d4
11+
with:
12+
repo-token: ${{ secrets.GITHUB_TOKEN }}
13+
stale-issue-message: 'This issue is stale because it has been open 60 days with no activity.'
14+
stale-pr-message: 'This PR is stale because it has been open 60 days with no activity.'
15+
days-before-stale: 60
16+
days-before-close: -1
17+
only-labels: 'engineering'
18+
stale-issue-label: 'stale'
19+
stale-pr-label: 'stale'
20+
exempt-pr-labels: 'never-stale'
21+
exempt-issue-labels: 'never-stale'

.github/workflows/auto-label-prs.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
name: Auto label Pull Requests
22
on:
3-
- pull_request
3+
pull_request:
44

55
jobs:
66
triage:
77
if: github.repository == 'github/docs-internal'
88
runs-on: ubuntu-latest
99
steps:
10-
- uses: actions/labeler@5f867a63be70efff62b767459b009290364495eb
11-
with:
12-
repo-token: "${{ secrets.GITHUB_TOKEN }}"
10+
- uses: actions/labeler@5f867a63be70efff62b767459b009290364495eb
11+
with:
12+
repo-token: '${{ secrets.GITHUB_TOKEN }}'

.github/workflows/automerge-dependencies.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@ name: Auto Merge Dependency Updates
33
on:
44
pull_request:
55
paths:
6-
- "package*.json"
7-
- "Gemfile*"
8-
- "Dockerfile"
9-
- ".github/workflows/**"
6+
- 'package*.json'
7+
- 'Gemfile*'
8+
- 'Dockerfile'
9+
- '.github/workflows/**'
1010
pull_request_review:
1111
types:
1212
- edited

.github/workflows/automerge.yml

+10-10
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,14 @@ jobs:
2323
if: contains(github.event.pull_request.labels.*.name, 'automerge') || contains(github.event.pull_request.labels.*.name, 'autosquash')
2424
steps:
2525
- name: automerge
26-
uses: "pascalgn/automerge-action@c9bd182"
26+
uses: 'pascalgn/automerge-action@c9bd182'
2727
env:
28-
GITHUB_TOKEN: "${{ secrets.OCTOMERGER_PAT_WITH_REPO_AND_WORKFLOW_SCOPE }}"
29-
MERGE_METHOD_LABELS: "automerge=merge,autosquash=squash"
30-
MERGE_COMMIT_MESSAGE: "pull-request-title"
31-
MERGE_METHOD: "merge"
32-
MERGE_FORKS: "true"
33-
MERGE_RETRIES: "50"
34-
MERGE_RETRY_SLEEP: "10000" # ten seconds
35-
UPDATE_LABELS: "automerge,autosquash"
36-
UPDATE_METHOD: "merge"
28+
GITHUB_TOKEN: '${{ secrets.OCTOMERGER_PAT_WITH_REPO_AND_WORKFLOW_SCOPE }}'
29+
MERGE_METHOD_LABELS: 'automerge=merge,autosquash=squash'
30+
MERGE_COMMIT_MESSAGE: 'pull-request-title'
31+
MERGE_METHOD: 'merge'
32+
MERGE_FORKS: 'true'
33+
MERGE_RETRIES: '50'
34+
MERGE_RETRY_SLEEP: '10000' # ten seconds
35+
UPDATE_LABELS: 'automerge,autosquash'
36+
UPDATE_METHOD: 'merge'

.github/workflows/check-all-english-links.yml

+20-20
Original file line numberDiff line numberDiff line change
@@ -3,30 +3,30 @@ name: Check all English links
33
on:
44
workflow_dispatch:
55
schedule:
6-
- cron: "40 19 * * *" # once a day at 19:40 UTC / 11:40 PST
6+
- cron: '40 19 * * *' # once a day at 19:40 UTC / 11:40 PST
77

88
jobs:
99
check_all_english_links:
1010
name: Check all links
1111
if: github.repository == 'github/docs-internal'
1212
runs-on: ubuntu-latest
1313
steps:
14-
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f
15-
- name: npm ci
16-
run: npm ci
17-
- name: npm run build
18-
run: npm run build
19-
- name: Run script
20-
run: script/check-english-links.js > broken_links.md
21-
- if: ${{ failure() }}
22-
name: Get title for issue
23-
id: check
24-
run: echo "::set-output name=title::$(head -1 broken_links.md)"
25-
- if: ${{ failure() }}
26-
name: Create issue from file
27-
uses: peter-evans/create-issue-from-file@35e304e2a12caac08c568247a2cb46ecd0c3ecc5
28-
with:
29-
token: ${{ secrets.DOCUBOT_FR_PROJECT_BOARD_WORKFLOWS_REPO_ORG_READ_SCOPES }}
30-
title: ${{ steps.check.outputs.title }}
31-
content-filepath: ./broken_links.md
32-
labels: broken link report
14+
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f
15+
- name: npm ci
16+
run: npm ci
17+
- name: npm run build
18+
run: npm run build
19+
- name: Run script
20+
run: script/check-english-links.js > broken_links.md
21+
- if: ${{ failure() }}
22+
name: Get title for issue
23+
id: check
24+
run: echo "::set-output name=title::$(head -1 broken_links.md)"
25+
- if: ${{ failure() }}
26+
name: Create issue from file
27+
uses: peter-evans/create-issue-from-file@35e304e2a12caac08c568247a2cb46ecd0c3ecc5
28+
with:
29+
token: ${{ secrets.DOCUBOT_FR_PROJECT_BOARD_WORKFLOWS_REPO_ORG_READ_SCOPES }}
30+
title: ${{ steps.check.outputs.title }}
31+
content-filepath: ./broken_links.md
32+
labels: broken link report

.github/workflows/codeql.yml

+10-10
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
1-
name: "CodeQL analysis"
1+
name: CodeQL analysis
22

33
on:
44
push:
55
paths:
6-
- '**/*.js'
7-
- '.github/workflows/codeql.yml'
6+
- '**/*.js'
7+
- '.github/workflows/codeql.yml'
88

99
jobs:
1010
build:
11-
runs-on: ubuntu-latest
11+
runs-on: ubuntu-latest
1212

1313
steps:
14-
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f
15-
- uses: github/codeql-action/init@v1
16-
with:
17-
languages: javascript # comma separated list of values from {go, python, javascript, java, cpp, csharp} (not YET ruby, sorry!)
18-
- uses: github/codeql-action/analyze@v1
19-
continue-on-error: true
14+
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f
15+
- uses: github/codeql-action/init@v1
16+
with:
17+
languages: javascript # comma separated list of values from {go, python, javascript, java, cpp, csharp} (not YET ruby, sorry!)
18+
- uses: github/codeql-action/analyze@v1
19+
continue-on-error: true

.github/workflows/crowdin.yml

+4-6
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: Crowdin Sync
33
on:
44
workflow_dispatch:
55
schedule:
6-
- cron: "33 2 * * *" # every day at 2:33 UTC at least until automerge is working
6+
- cron: '33 2 * * *' # every day at 2:33 UTC at least until automerge is working
77

88
jobs:
99
sync_with_crowdin:
@@ -20,7 +20,7 @@ jobs:
2020
upload_translations: false
2121
download_translations: true
2222
create_pull_request: true
23-
23+
2424
# Using a custom config temporarily to avoid clobbering the existing crowdin.yml
2525
# that is used by the github-help-docs OAuth integration.
2626
config: 'crowdin.yml'
@@ -35,17 +35,15 @@ jobs:
3535
crowdin_branch_name: main
3636

3737
env:
38-
# Using an @octoglot token instead of the default Actions-provided GITHUB_TOKEN here
38+
# Using an @octoglot token instead of the default Actions-provided GITHUB_TOKEN here
3939
# so that subsequent workflows will be able to run on the pull request created by this workflow.
4040
GITHUB_TOKEN: ${{ secrets.OCTOGLOT_PAT_WITH_REPO_AND_WORKFLOW_SCOPE }}
4141

4242
# This is a numeric id, not to be confused with Crowdin API v1 "project identifier" string
4343
# See "API v2" on https://crowdin.com/project/<your-project>/settings#api
4444
CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }}
45-
45+
4646
# A personal access token, not to be confused with Crowdin API v1 "API key"
4747
# See https://crowdin.com/settings#api-key to generate a token
4848
# This token was created by logging into Crowdin with the octoglot user
4949
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }}
50-
51-

.github/workflows/dry-run-sync-algolia-search-indices.yml

+20-20
Original file line numberDiff line numberDiff line change
@@ -9,23 +9,23 @@ jobs:
99
if: github.repository == 'github/docs-internal'
1010
runs-on: ubuntu-latest
1111
steps:
12-
- name: checkout
13-
uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f
14-
- uses: actions/setup-node@56899e050abffc08c2b3b61f3ec6a79a9dc3223d
15-
with:
16-
node-version: 14.x
17-
- name: cache node modules
18-
uses: actions/cache@0781355a23dac32fd3bac414512f4b903437991a
19-
with:
20-
path: ~/.npm
21-
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
22-
restore-keys: |
23-
${{ runner.os }}-node-
24-
- name: npm ci
25-
run: npm ci
26-
- name: (Dry run) sync indices
27-
env:
28-
ALGOLIA_APPLICATION_ID: ${{ secrets.ALGOLIA_APPLICATION_ID }}
29-
ALGOLIA_API_KEY: ${{ secrets.ALGOLIA_API_KEY }}
30-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
31-
run: npm run sync-search-dry-run
12+
- name: checkout
13+
uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f
14+
- uses: actions/setup-node@56899e050abffc08c2b3b61f3ec6a79a9dc3223d
15+
with:
16+
node-version: 14.x
17+
- name: cache node modules
18+
uses: actions/cache@0781355a23dac32fd3bac414512f4b903437991a
19+
with:
20+
path: ~/.npm
21+
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
22+
restore-keys: |
23+
${{ runner.os }}-node-
24+
- name: npm ci
25+
run: npm ci
26+
- name: (Dry run) sync indices
27+
env:
28+
ALGOLIA_APPLICATION_ID: ${{ secrets.ALGOLIA_APPLICATION_ID }}
29+
ALGOLIA_API_KEY: ${{ secrets.ALGOLIA_API_KEY }}
30+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
31+
run: npm run sync-search-dry-run

0 commit comments

Comments
 (0)