chore: resolve docs list from cwd
This commit is contained in:
@@ -1,8 +1,7 @@
|
||||
#!/usr/bin/env tsx
|
||||
|
||||
import { readdirSync, readFileSync } from 'node:fs';
|
||||
import { dirname, join, relative } from 'node:path';
|
||||
import { fileURLToPath } from 'node:url';
|
||||
import { join, relative } from 'node:path';
|
||||
|
||||
process.stdout.on('error', (error) => {
|
||||
if ((error as NodeJS.ErrnoException).code === 'EPIPE') {
|
||||
@@ -11,9 +10,7 @@ process.stdout.on('error', (error) => {
|
||||
throw error;
|
||||
});
|
||||
|
||||
const docsListFile = fileURLToPath(import.meta.url);
|
||||
const docsListDir = dirname(docsListFile);
|
||||
const DOCS_DIR = join(docsListDir, '..', 'docs');
|
||||
const DOCS_DIR = join(process.cwd(), 'docs');
|
||||
|
||||
const EXCLUDED_DIRS = new Set(['archive', 'research']);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user