Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
90e33af
Add workflows for translation sync and PR creation
MDC91 Feb 14, 2026
e9fffdc
Create test-translation.yml
MDC91 Feb 14, 2026
dfe4c70
Update test-translation.yml
MDC91 Feb 14, 2026
b7d3f6f
Test translation: introduction.md
Feb 14, 2026
c43fe3f
Improve translation workflow frontmatter handling
MDC91 Feb 14, 2026
86d8d3f
Test translation: introduction.md
Feb 14, 2026
b812752
Update test-translation.yml
MDC91 Feb 14, 2026
e15aef9
Delete introduction.md
MDC91 Feb 14, 2026
7758fa7
Test translation: introduction.md
Feb 14, 2026
fdd770b
Enhance translation workflows and parser
MDC91 Feb 14, 2026
a8f2c66
Update sync-and-translate.yml
MDC91 Feb 14, 2026
13ea734
Update sync-and-translate.yml
MDC91 Feb 14, 2026
33d5483
Add branch cleanup workflow; use action for PRs
MDC91 Feb 14, 2026
579c114
Refactor translation workflow and remove DE intro
MDC91 Feb 14, 2026
64bf31f
Translation sync: $(date +%Y-%m-%d)
MDC91 Feb 14, 2026
3cb3388
Fix typos and improve German translation in introduction
MDC91 Feb 14, 2026
01fc6ab
Update German translation in overview.md
MDC91 Feb 14, 2026
8d194fb
Revise titles and descriptions in key-features.md
MDC91 Feb 14, 2026
44a605c
Update consensus.md for clarity and consistency
MDC91 Feb 14, 2026
a22dc79
Refine translation rules and remove test workflow
MDC91 Feb 15, 2026
f15af95
Merge pull request #2 from MDC91/translation-sync-22024566140
MDC91 Feb 16, 2026
5624e47
Disable automated workflows pending translations
MDC91 Feb 16, 2026
74d323f
Merge branch 'main' of https://github.com/MDC91/qubic-docs-de
MDC91 Feb 16, 2026
25afff5
Enable manual trigger for upstream PR workflow
MDC91 Feb 16, 2026
1941006
Fix upstream PR workflow to use cross-repository PR
MDC91 Feb 16, 2026
054d7a4
Fix upstream PR workflow commit logic
MDC91 Feb 16, 2026
bd09499
Add German translations
Feb 16, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions .github/workflows/cleanup-branches.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Cleanup Old Branches

on:
pull_request:
types: [closed]
branches: [main]

jobs:
cleanup:
runs-on: ubuntu-latest
if: github.event.pull_request.merged == true

steps:
- name: Delete merged branch
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
BRANCH_NAME="${{ github.event.pull_request.head.ref }}"

# Nur translation-sync Branches lΓΆschen
if [[ $BRANCH_NAME == translation-sync-* ]]; then
echo "LΓΆsche Branch: $BRANCH_NAME"
git push origin --delete $BRANCH_NAME || echo "Branch konnte nicht gelΓΆscht werden (mΓΆglicherweise schon gelΓΆscht)"
echo "βœ“ Branch $BRANCH_NAME wurde gelΓΆscht"
else
echo "Branch $BRANCH_NAME ist kein Translation-Branch, ΓΌberspringe"
fi
130 changes: 130 additions & 0 deletions .github/workflows/create-upstream-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,130 @@
name: Create Upstream PR

on:
pull_request:
types: [closed]
branches: [main]
workflow_dispatch: # Manuelles Triggern mΓΆglich

jobs:
create-upstream-pr:
if: github.event_name == 'workflow_dispatch' || (github.event.pull_request.merged == true && contains(github.event.pull_request.title, '[REVIEW NEEDED]'))
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write

steps:
- name: Checkout your fork
uses: actions/checkout@v4
with:
repository: ${{ github.actor }}/qubic-docs-de
token: ${{ secrets.UPSTREAM_PR_TOKEN }}
fetch-depth: 0

- name: Configure Git
run: |
git config user.name "Qubic Translation Bot"
git config user.email "translation-bot@qubic-network.de"

- name: Create branch with only translations
run: |
# Neuen Branch erstellen
BRANCH_NAME="german-translations-$(date +%Y%m%d)"
git checkout -b $BRANCH_NAME

# Nur i18n/de/ behalten, Rest entfernen
mkdir -p /tmp/translations
cp -r i18n/de/ /tmp/translations/

# Alles lâschen außer .git
find . -mindepth 1 -maxdepth 1 ! -name '.git' -exec rm -rf {} +

# i18n wiederherstellen
mkdir -p i18n
cp -r /tmp/translations/de/ i18n/

# Alles stage (inkl. LΓΆschungen) und dann nur i18n commiten
git add -A
git reset HEAD .github/workflows/cleanup-branches.yml .github/workflows/create-upstream-pr.yml .github/workflows/sync-and-translate.yml 2>/dev/null || true
git commit -m "Add German translations

- Translated via DeepSeek API with human review
- Covers latest documentation updates
- All technical terms preserved
- Includes overview section

Co-authored-by: ${{ github.actor }}"

# Branch pushen
git push origin $BRANCH_NAME

echo "branch_name=$BRANCH_NAME" >> $GITHUB_ENV
echo "βœ“ Branch $BRANCH_NAME erstellt und gepusht"

- name: Create Pull Request to qubic/docs
env:
GITHUB_TOKEN: ${{ secrets.UPSTREAM_PR_TOKEN }}
run: |
# Cross-Repository PR erstellen
gh pr create \
--repo qubic/docs \
--title "German Translation Update - $(date +%Y-%m-%d)" \
--body "$(cat << 'PRBODY'
## πŸ‡©πŸ‡ͺ German Translation Update

This PR adds German translations for the Qubic documentation.

### What's included:
- βœ… Latest translations synchronized with upstream
- βœ… AI-translated via DeepSeek API
- βœ… Reviewed by human translator
- βœ… All technical terms preserved
- βœ… Proper Docusaurus i18n structure (`i18n/de/`)

### Files changed:
- German translations in `i18n/de/docusaurus-plugin-content-docs/current/`

### How to test:
1. Pull this branch
2. Add to `docusaurus.config.js`:
```javascript
i18n: {
defaultLocale: 'en',
locales: ['en', 'de'],
}
```
3. Run `npm run start`
4. Visit `http://localhost:3000/de/`

### Requirements for merge:
- [ ] Add `de` to `locales` in `docusaurus.config.js`
- [ ] Verify build succeeds: `npm run build`
- [ ] Check German pages render correctly

### Maintenance:
- Translations are automatically synced daily
- New PRs will be created for future updates
- This is a one-time setup - future updates just need merge

---
*Automated translation workflow by @${{ github.actor }}*
*For questions about translations, please contact the German translation team*
PRBODY
)" \
--head ${{ github.actor }}:${{ env.branch_name }} \
--base main

- name: Notify success
run: |
echo "========================================"
echo "βœ… PR erfolgreich erstellt!"
echo ""
echo "Der Qubic-Maintainer bekommt jetzt:"
echo "- Nur den i18n/de/ Ordner"
echo "- Keine Workflow-Dateien"
echo "- Keine Scripts"
echo ""
echo "Link zum PR:"
echo "https://github.com/qubic/docs/pulls"
echo "========================================"
Loading