Skip to content

Commit 9118a30

Browse files
committed
ci: let's debug
1 parent 5c9285d commit 9118a30

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

src/cli/lint.ts

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,14 @@ import type { Options } from '@cspell/eslint-plugin'
22
import cspellRecommended from '@cspell/eslint-plugin/recommended'
33
import js from '@eslint/js'
44
import react from '@eslint-react/eslint-plugin'
5+
import { logger } from '@rspress/shared/logger'
56
import { Command } from 'commander'
67
import { merge } from 'es-toolkit/compat'
78
import { ESLint } from 'eslint'
89
import * as mdx from 'eslint-plugin-mdx'
910
import tseslint from 'typescript-eslint'
1011

12+
import type { NormalizedTermItem } from '../terms.js'
1113
import type { GlobalCliOptions } from '../types.js'
1214

1315
import { parseTerms } from './helpers.js'
@@ -23,7 +25,13 @@ export const lintCommand = new Command('lint')
2325

2426
const docsDir = config.root!
2527

26-
const parsedTerms = await parseTerms()
28+
let parsedTerms: NormalizedTermItem[] = []
29+
30+
try {
31+
parsedTerms = await parseTerms()
32+
} catch (err) {
33+
logger.error('Failed to parse terms.yaml', err)
34+
}
2735

2836
const eslint = new ESLint({
2937
cwd: docsDir,

0 commit comments

Comments
 (0)