Skip to content

Commit a8a316b

Browse files
authored
Improve debug-review.yml
1 parent 11258c0 commit a8a316b

File tree

1 file changed

+28
-20
lines changed

1 file changed

+28
-20
lines changed

.github/workflows/debug-review.yml

Lines changed: 28 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -25,18 +25,16 @@ jobs:
2525
cd docusaurus
2626
yarn add --dev js-yaml glob
2727
28-
- name: Debug - Check file structure
28+
- name: Debug - Check file structure in detail
2929
run: |
30-
echo "=== Repository structure ==="
31-
ls -la
32-
echo "=== Docusaurus directory ==="
33-
ls -la docusaurus/
34-
echo "=== Scripts directory ==="
35-
ls -la docusaurus/scripts/ || echo "scripts directory not found"
36-
echo "=== Style validation directory ==="
37-
ls -la docusaurus/scripts/style-validation/ || echo "style-validation directory not found"
38-
echo "=== Docs directory ==="
39-
ls -la docusaurus/docs/ | head -10
30+
echo "=== Current working directory ==="
31+
pwd
32+
echo "=== Full repository structure ==="
33+
find . -name "*.md" -o -name "*.mdx" | head -20
34+
echo "=== Specifically looking for docs ==="
35+
find . -type d -name "docs"
36+
echo "=== Content of any docs directories ==="
37+
find . -type d -name "docs" -exec echo "=== {} ===" \; -exec ls -la {} \; | head -30
4038
4139
- name: Test validation script existence
4240
run: |
@@ -69,18 +67,28 @@ jobs:
6967
echo "❌ YAML config NOT found"
7068
fi
7169
72-
- name: Try running validation with debug
70+
- name: Try running validation with different paths
7371
run: |
7472
cd docusaurus
75-
echo "=== Attempting to run validation ==="
76-
if [ -f "scripts/style-validation/validate-content-style.js" ]; then
77-
echo "Running validation script..."
78-
node scripts/style-validation/validate-content-style.js --verbose || echo "Validation script failed"
73+
echo "=== Current directory after cd ==="
74+
pwd
75+
echo "=== Looking for docs from here ==="
76+
ls -la docs/ | head -10 || echo "No docs/ directory here"
77+
78+
echo "=== Testing glob patterns ==="
79+
echo "Pattern: docs/**/*.md"
80+
node -e "const glob = require('glob'); console.log('Files found:', glob.sync('docs/**/*.{md,mdx}').slice(0, 10));"
81+
82+
echo "=== Testing absolute patterns ==="
83+
node -e "const glob = require('glob'); const path = require('path'); const pattern = path.join(process.cwd(), 'docs', '**/*.{md,mdx}'); console.log('Pattern:', pattern); console.log('Files found:', glob.sync(pattern).slice(0, 10));"
84+
85+
echo "=== Manual test with specific files ==="
86+
if [ -f "docs/cms/intro.md" ]; then
87+
echo "Testing with specific file..."
88+
node scripts/style-validation/validate-content-style.js --verbose docs/cms/intro.md || echo "Failed with specific file"
7989
else
80-
echo "Creating minimal test to see what happens..."
81-
mkdir -p scripts/style-validation
82-
echo "console.log('Test script running'); process.exit(0);" > scripts/style-validation/test.js
83-
node scripts/style-validation/test.js
90+
echo "docs/cms/intro.md not found"
91+
find . -name "intro.md" || echo "No intro.md found anywhere"
8492
fi
8593
8694
- name: Check if results file was created

0 commit comments

Comments
 (0)