Skip to content

Commit 4e7eaa1

Browse files
committed
chore: remove lychee link verification
Lychee is an unreliable dependency. The URL resolution fix for GITHUB_REPOSITORY fallback is already in place.
1 parent 467c205 commit 4e7eaa1

File tree

1 file changed

+0
-49
lines changed

1 file changed

+0
-49
lines changed

tools/build-docs.js

Lines changed: 0 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -117,61 +117,12 @@ function buildAstroSite() {
117117
runAstroBuild();
118118
copyArtifactsToSite(artifactsDir, siteDir);
119119

120-
// Verify all links in built site
121-
verifyBuiltLinks(siteDir);
122-
123120
console.log();
124121
console.log(` \u001B[32m✓\u001B[0m Astro build complete`);
125122

126123
return siteDir;
127124
}
128125

129-
/**
130-
* Verify all internal links in the built site using lychee.
131-
* Starts a local server and crawls the site.
132-
*/
133-
function verifyBuiltLinks(siteDir) {
134-
// TEMPORARY: Only run for local dev (remove before merging)
135-
if (require('node:os').userInfo().username !== 'alex') {
136-
console.log(' → Skipping link verification (CI)');
137-
return;
138-
}
139-
140-
console.log(' → Verifying links in built site...');
141-
142-
const { spawn } = require('node:child_process');
143-
const url = new URL(SITE_URL);
144-
const port = url.port || '4321';
145-
146-
// Start local server
147-
const serverProcess = spawn('npx', ['serve', siteDir, '-l', port, '--single'], {
148-
cwd: PROJECT_ROOT,
149-
stdio: 'pipe',
150-
detached: true,
151-
});
152-
153-
// Wait for server to start
154-
execSync('sleep 2');
155-
156-
try {
157-
execSync(`lychee 'http://localhost:${port}/' --no-progress`, {
158-
cwd: PROJECT_ROOT,
159-
stdio: 'inherit',
160-
});
161-
console.log(` \u001B[32m✓\u001B[0m Link verification passed`);
162-
} catch {
163-
console.error(`\n \u001B[31m✗\u001B[0m Link verification failed - fix broken links before deploying\n`);
164-
process.kill(-serverProcess.pid);
165-
process.exit(1);
166-
} finally {
167-
try {
168-
process.kill(-serverProcess.pid);
169-
} catch {
170-
// Server already stopped
171-
}
172-
}
173-
}
174-
175126
// =============================================================================
176127
// LLM File Generation
177128
/**

0 commit comments

Comments
 (0)