Skip to content

Commit 6fea7c0

Browse files
committed
Merge branch 'main' of https://github.com/ClickHouse/clickhouse-docs into v2_usecases_docs
2 parents e2b8569 + 31589e2 commit 6fea7c0

File tree

12,301 files changed

+1079495
-121340
lines changed

Some content is hidden

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

12,301 files changed

+1079495
-121340
lines changed

.github/CODEOWNERS

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
* @ClickHouse/docs
2-
/docs/integrations/ @ClickHouse/integrations @ClickHouse/docs
2+
/docs/integrations/ @ClickHouse/integrations-ecosystem @ClickHouse/docs
3+
/docs/integrations/data-ingestion/clickpipes/ @ClickHouse/clickpipes @ClickHouse/docs
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Translation Issue Report
2+
description: File a report for translated documentation.
3+
title: "[translation issue]: "
4+
labels: ["translation issue"]
5+
body:
6+
- type: markdown
7+
attributes:
8+
value: |
9+
Please report any problems found with translations of the documentation
10+
using this form.
11+
- type: dropdown
12+
id: language
13+
attributes:
14+
label: Language
15+
description: For which language are you reporting a translation issue?
16+
options:
17+
- Русский (Russian)
18+
- 中文 (Mandarin)
19+
- 日本語 (Japanese)
20+
default: 0
21+
validations:
22+
required: true
23+
- type: input
24+
id: url
25+
attributes:
26+
label: URL to page
27+
description: Please provide the URL of the page in question.
28+
placeholder: eg. https://clickhouse.com/docs/ru/architecture/replication
29+
validations:
30+
required: true
31+
- type: textarea
32+
id: problem
33+
attributes:
34+
label: What is the problem?
35+
description: Please tell us what the problem is
36+
placeholder: Tell us what you see!
37+
value: "The translation issue on this page is..."
38+
validations:
39+
required: true
Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
name: Weekly Badge Monitor
2+
3+
on:
4+
schedule:
5+
# Run every Monday at 10:00 AM Amsterdam time (UTC+1/+2)
6+
# Using 8:00 UTC to account for Amsterdam time (adjusts for DST)
7+
- cron: '0 8 * * 1'
8+
workflow_dispatch: # Allow manual triggering
9+
10+
jobs:
11+
monitor-badges:
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- name: Checkout repository
16+
uses: actions/checkout@v4
17+
18+
- name: Make script executable
19+
run: chmod +x scripts/badger.sh
20+
21+
- name: Run badge finder script
22+
id: find_badges
23+
run: |
24+
# Run the script and capture output
25+
SCRIPT_OUTPUT=$(scripts/badger.sh)
26+
27+
# Escape the output for JSON and store in GitHub output
28+
# Replace newlines with \n and escape quotes
29+
ESCAPED_OUTPUT=$(echo "$SCRIPT_OUTPUT" | sed 's/\\/\\\\/g' | sed 's/"/\\"/g' | sed ':a;N;$!ba;s/\n/\\n/g')
30+
31+
echo "badges_output<<EOF" >> $GITHUB_OUTPUT
32+
echo "$ESCAPED_OUTPUT" >> $GITHUB_OUTPUT
33+
echo "EOF" >> $GITHUB_OUTPUT
34+
35+
- name: Send webhook
36+
env:
37+
WEBHOOK_URL: ${{ secrets.DOCS_BADGER }}
38+
BADGES_OUTPUT: ${{ steps.find_badges.outputs.badges_output }}
39+
run: |
40+
# Create JSON payload
41+
JSON_PAYLOAD=$(cat <<EOF
42+
{
43+
"badges_list": "$BADGES_OUTPUT"
44+
}
45+
EOF
46+
)
47+
48+
# Send webhook
49+
curl -X POST \
50+
-H "Content-Type: application/json" \
51+
-d "$JSON_PAYLOAD" \
52+
"$WEBHOOK_URL"
53+
54+
- name: Log completion
55+
run: |
56+
echo "Badge monitoring completed successfully"
57+
echo "Webhook sent to configured endpoint"

.github/workflows/build-search.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
node-version: '20'
2929

3030
- name: Run Prep from Master
31-
run: yarn copy-clickhouse-repo-docs
31+
run: yarn copy-clickhouse-repo-docs -f
3232

3333
- name: Run Auto Generate Settings
3434
run: yarn autogenerate-settings

.github/workflows/check-build.yml

Lines changed: 24 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -16,23 +16,19 @@ jobs:
1616
runs-on: ubuntu-latest
1717
strategy:
1818
matrix:
19-
check_type: [spellcheck, kbcheck, md-lint]
19+
check_type: [spellcheck, kbcheck, md-lint, glossary-check]
2020
steps:
2121
# Add setup steps per check here
2222
- uses: actions/checkout@v4
2323
- name: Install Aspell
2424
if: matrix.check_type == 'spellcheck'
2525
run: sudo apt-get update && sudo apt-get install -y aspell aspell-en
2626
- name: Set up Python
27-
if: matrix.check_type == 'kbcheck'
28-
uses: actions/setup-python@v5
29-
with:
30-
python-version: '3.x'
31-
- name: Install dependencies
32-
if: matrix.check_type == 'kbcheck'
27+
if: matrix.check_type == 'kbcheck' || matrix.check_type == 'glossary-check'
3328
run: |
34-
python -m pip install --upgrade pip
35-
pip install -r 'scripts/knowledgebase-checker/requirements.txt'
29+
curl -Ls https://astral.sh/uv/install.sh | sh
30+
uv clean
31+
uv python install 3.12 --verbose
3632
- name: Setup md-lint environment
3733
if: matrix.check_type == 'md-lint'
3834
uses: actions/setup-node@v3
@@ -43,31 +39,25 @@ jobs:
4339
run: yarn add -D markdownlint-cli2
4440

4541
# Run the checks here
46-
- name: Run checks
47-
id: check_step
48-
run: |
49-
if [[ "${{ matrix.check_type }}" == "spellcheck" ]]; then
50-
./scripts/check-doc-aspell
51-
exit_code=$?
52-
elif [[ "${{ matrix.check_type }}" == "kbcheck" ]]; then
53-
./scripts/knowledgebase-checker/knowledgebase_article_checker.py --kb-dir="knowledgebase"
54-
exit_code=$?
55-
elif [[ "${{ matrix.check_type }}" == "md-lint" ]]; then
56-
yarn markdownlint-cli2 --config ./scripts/.markdownlint-cli2.yaml 'docs/**/*.md'
57-
exit_code=$?
58-
fi
59-
60-
if [[ $exit_code -ne 0 ]]; then
61-
echo "::error::${{ matrix.check_type }} check failed. See logs for details."
62-
exit 1
63-
fi
42+
- name: Run spellcheck
43+
if: matrix.check_type == 'spellcheck'
44+
run: yarn check-spelling
6445

65-
- name: Set check status
66-
if: steps.check_step.outcome != 'success'
67-
uses: actions/github-script@v6
68-
with:
69-
script: |
70-
core.setFailed('${{ matrix.check_type }} check failed.');
46+
- name: Run KB check
47+
if: matrix.check_type == 'kbcheck'
48+
run: yarn check-kb
49+
50+
- name: Run markdown lint
51+
if: matrix.check_type == 'md-lint'
52+
run: yarn check-markdown
53+
54+
- name: Run glossary check
55+
if: matrix.check_type == 'glossary-check'
56+
run: |
57+
echo "Extracting glossary from markdown..."
58+
python3 scripts/glossary/extract-glossary-terms.py
59+
echo "Checking glossary coverage..."
60+
python3 scripts/glossary/wrap-glossary-terms.py --check || echo "::warning::Glossary check found unwrapped terms (non-blocking)"
7161
7262
check_overall_status:
7363
needs: stylecheck
@@ -78,5 +68,4 @@ jobs:
7868
if: needs.stylecheck.result != 'success'
7969
run: |
8070
echo "::error::One or more checks of the style check failed."
81-
exit 1
82-
71+
exit 1

.github/workflows/linkcheck.yml

Lines changed: 0 additions & 77 deletions
This file was deleted.
Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
name: PullRequestCI
2+
3+
env:
4+
# Force the stdout and stderr streams to be unbuffered
5+
PYTHONUNBUFFERED: 1
6+
7+
on: # yamllint disable-line rule:truthy
8+
pull_request:
9+
types:
10+
- synchronize
11+
- reopened
12+
- opened
13+
14+
# Cancel the previous wf run in PRs.
15+
concurrency:
16+
group: ${{ github.workflow }}-${{ github.ref }}
17+
cancel-in-progress: true
18+
19+
jobs:
20+
DocsCheck:
21+
runs-on: ubuntu-latest
22+
steps:
23+
- name: Checkout repository
24+
uses: actions/checkout@v3
25+
26+
- name: Set up Node.js
27+
uses: actions/setup-node@v3
28+
with:
29+
node-version: '20' # Adjust Node.js version as needed
30+
cache: 'yarn' # Cache yarn dependencies
31+
32+
- name: Install dependencies
33+
run: yarn install --frozen-lockfile
34+
35+
- name: Build
36+
id: build
37+
continue-on-error: true
38+
run: |
39+
DOCUSAURUS_IGNORE_SSG_WARNINGS=true yarn build
40+
echo "exit_code=$?" >> $GITHUB_OUTPUT
41+
42+
- name: Check for validation failures
43+
if: success() || failure() # Run regardless of build success
44+
run: |
45+
FAILED=false
46+
47+
if [ -f ".frontmatter-validation-failed" ]; then
48+
echo "::error::Frontmatter validation failed"
49+
FAILED=true
50+
fi
51+
52+
if [ -f ".floating-pages-validation-failed" ]; then
53+
echo "::error::Floating pages validation failed"
54+
FAILED=true
55+
fi
56+
57+
# Check if build failed with non-validation error
58+
if [ "${{ steps.build.outputs.exit_code }}" != "0" ] && [ "$FAILED" != "true" ]; then
59+
echo "::error::Build failed with exit code ${{ steps.build.outputs.exit_code }}"
60+
exit 1
61+
fi
62+
63+
if [ "$FAILED" = true ]; then
64+
exit 1
65+
fi

.github/workflows/pull-request.yml

Lines changed: 0 additions & 54 deletions
This file was deleted.

0 commit comments

Comments
 (0)