From 6a5705648d9cda7fb86da300535f1e70c8afa8f1 Mon Sep 17 00:00:00 2001 From: Erica Pescio Date: Thu, 23 Apr 2026 10:53:07 +0200 Subject: [PATCH 1/4] ci(docs-linting):added support to complex doc structures --- .github/workflows/reusable-docs-linting.yml | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/.github/workflows/reusable-docs-linting.yml b/.github/workflows/reusable-docs-linting.yml index 735f33f..fe5550a 100644 --- a/.github/workflows/reusable-docs-linting.yml +++ b/.github/workflows/reusable-docs-linting.yml @@ -25,18 +25,30 @@ jobs: exit 1 fi - name: Check whether docs exists and contains a README + id: check-readme run: | if [ -d "./docs" ]; then echo "Folder exists." if [ ! -f "./docs/readme.md" ]; then - echo "❌ docs/readme.md file is missing" - exit 1 + # Check for other markdown files in docs and its subfolders + md_count=$(find ./docs -type f -name "*.md" | wc -l) + if [ "$md_count" -gt 0 ]; then + echo "✅ docs/readme.md is missing, but found $md_count markdown file(s) in docs/." + echo "has_simple_readme=false" >> $GITHUB_OUTPUT + else + echo "❌ docs/readme.md is missing and no other markdown files found in docs/." + exit 1 + fi + else + echo "✅ docs/readme.md exists." + echo "has_simple_readme=true" >> $GITHUB_OUTPUT fi else echo "❌ Folder 'docs' does not exist." exit 1 fi - name: Check for required sections in Documentation + if: steps.check-readme.outputs.has_simple_readme == 'true' run: | patterns=( "#{1,3} Contributing" @@ -53,12 +65,14 @@ jobs: fi done - name: Check for empty sections + if: steps.check-readme.outputs.has_simple_readme == 'true' run: | if grep -Eq "^#+ .+\\n(?:\\n[#+|$]|[#+|$])" docs/readme.md; then echo "Empty section found in docs/readme.md ❌ Please add content" exit 1 fi - name: Check for incomplete sections + if: steps.check-readme.outputs.has_simple_readme == 'true' run: | if grep -Eq "TODO" docs/readme.md; then echo "Found 'TODO' in one or more paragraphs in docs/readme.md ❌ Please add proper content" @@ -76,7 +90,8 @@ jobs: # Download and install packages vale sync # Execute - vale --output=JSON docs/*.md > vale-report.json || true + # vale --output=JSON docs/*.md > vale-report.json || true + find ./docs -type f -name "*.md" -print0 | xargs -0 vale --output=JSON > vale-report.json || true - name: Upload Results uses: actions/upload-artifact@v6 From a56a57e6c1c03b7908df5880d9800a92160525ca Mon Sep 17 00:00:00 2001 From: Erica Pescio Date: Thu, 23 Apr 2026 12:00:12 +0200 Subject: [PATCH 2/4] ci(docs-deploy):copying docs instead of moving over --- .github/workflows/reusable-docs-deploy.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/reusable-docs-deploy.yml b/.github/workflows/reusable-docs-deploy.yml index 5a23ac9..a485295 100644 --- a/.github/workflows/reusable-docs-deploy.yml +++ b/.github/workflows/reusable-docs-deploy.yml @@ -32,7 +32,7 @@ jobs: run: | cp -r dotgithub/documentation/boilerplate ./website rm -rf website/docs ./website/docusaurus.config.ts README.md .gitignore - mv current-repo/docs ./website/docs + cp -r current-repo/docs ./website/docs cp current-repo/website/docusaurus.config.ts ./website/docusaurus.config.ts # Rename package.json depending on repo name REPO_NAME="${{ github.event.repository.name }}" From 54e308cd959aeec675785d56e28b348423db16ef Mon Sep 17 00:00:00 2001 From: Erica Pescio Date: Thu, 23 Apr 2026 12:33:35 +0200 Subject: [PATCH 3/4] ci(docs-deploy):restored mv docs instead of copying --- .github/workflows/reusable-docs-deploy.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/reusable-docs-deploy.yml b/.github/workflows/reusable-docs-deploy.yml index a485295..5a23ac9 100644 --- a/.github/workflows/reusable-docs-deploy.yml +++ b/.github/workflows/reusable-docs-deploy.yml @@ -32,7 +32,7 @@ jobs: run: | cp -r dotgithub/documentation/boilerplate ./website rm -rf website/docs ./website/docusaurus.config.ts README.md .gitignore - cp -r current-repo/docs ./website/docs + mv current-repo/docs ./website/docs cp current-repo/website/docusaurus.config.ts ./website/docusaurus.config.ts # Rename package.json depending on repo name REPO_NAME="${{ github.event.repository.name }}" From 442f371e452a7de95bf260aaf4d6ecfc366592d6 Mon Sep 17 00:00:00 2001 From: Erica Pescio Date: Thu, 23 Apr 2026 13:24:05 +0200 Subject: [PATCH 4/4] style:removed commented line --- .github/workflows/reusable-docs-linting.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/reusable-docs-linting.yml b/.github/workflows/reusable-docs-linting.yml index fe5550a..7475932 100644 --- a/.github/workflows/reusable-docs-linting.yml +++ b/.github/workflows/reusable-docs-linting.yml @@ -90,7 +90,6 @@ jobs: # Download and install packages vale sync # Execute - # vale --output=JSON docs/*.md > vale-report.json || true find ./docs -type f -name "*.md" -print0 | xargs -0 vale --output=JSON > vale-report.json || true - name: Upload Results