Translations: fix sidebar in Mandarin for Japanese pages #3737
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
name: Style check | |
env: | |
# Force the stdout and stderr streams to be unbuffered | |
PYTHONUNBUFFERED: 1 | |
on: | |
pull_request: | |
types: | |
- synchronize | |
- reopened | |
- opened | |
jobs: | |
stylecheck: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
check_type: [spellcheck, kbcheck, md-lint, glossary-check] | |
steps: | |
# Add setup steps per check here | |
- uses: actions/checkout@v4 | |
- name: Install Aspell | |
if: matrix.check_type == 'spellcheck' | |
run: sudo apt-get update && sudo apt-get install -y aspell aspell-en | |
- name: Set up Python | |
if: matrix.check_type == 'kbcheck' || matrix.check_type == 'glossary-check' | |
run: | | |
curl -Ls https://astral.sh/uv/install.sh | sh | |
uv clean | |
uv python install 3.12 --verbose | |
- name: Setup md-lint environment | |
if: matrix.check_type == 'md-lint' | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 20 | |
- name: Install markdownlint-cli2 | |
if: matrix.check_type == 'md-lint' | |
run: yarn add -D markdownlint-cli2 | |
# Run the checks here | |
- name: Run spellcheck | |
if: matrix.check_type == 'spellcheck' | |
run: yarn check-spelling | |
- name: Run KB check | |
if: matrix.check_type == 'kbcheck' | |
run: yarn check-kb | |
- name: Run markdown lint | |
if: matrix.check_type == 'md-lint' | |
run: yarn check-markdown | |
- name: Run glossary check | |
if: matrix.check_type == 'glossary-check' | |
run: | | |
echo "Extracting glossary from markdown..." | |
python3 scripts/glossary/extract-glossary-terms.py | |
echo "Checking glossary coverage..." | |
python3 scripts/glossary/wrap-glossary-terms.py --check || echo "::warning::Glossary check found unwrapped terms (non-blocking)" | |
check_overall_status: | |
needs: stylecheck | |
runs-on: ubuntu-latest | |
if: always() # run the job even if stylecheck fails | |
steps: | |
- name: Check overall results | |
if: needs.stylecheck.result != 'success' | |
run: | | |
echo "::error::One or more checks of the style check failed." | |
exit 1 |