Skip to content

Commit 8897946

Browse files
committed
chore: lint
1 parent 6c2727e commit 8897946

2 files changed

Lines changed: 6 additions & 4 deletions

File tree

src/agent/prompts/optional/validate.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ export function checkSourceCoverage(content: string, minRatio = 0.8): SectionVal
3232

3333
/** Warns if source links are missing .skilld/ prefix */
3434
export function checkSourcePaths(content: string): SectionValidationWarning[] {
35-
const badPaths = content.match(/\[source\]\(\.\/(?!\.skilld\/)(docs|issues|discussions|releases|pkg|guide)\//g)
35+
const badPaths = content.match(/\[source\]\(\.\/(docs|issues|discussions|releases|pkg|guide)\//g)
3636
if (badPaths?.length)
3737
return [{ warning: `${badPaths.length} source links missing .skilld/ prefix` }]
3838
return []

src/commands/validate.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,22 +38,24 @@ export const validateCommandDef = defineCommand({
3838
description: 'Section type (api-changes, best-practices, custom). Auto-detected from heading if omitted.',
3939
},
4040
},
41+
42+
/* eslint-disable no-console */
4143
async run({ args }) {
4244
const filePath = args.file as string
4345
if (!existsSync(filePath)) {
44-
console.error(`ERROR: File not found: ${filePath}`)
46+
console.error(`File not found: ${filePath}`)
4547
process.exit(1)
4648
}
4749

4850
const content = readFileSync(filePath, 'utf-8').trim()
4951
if (!content) {
50-
console.error('ERROR: File is empty')
52+
console.error('File is empty')
5153
process.exit(1)
5254
}
5355

5456
const section = (args.section as SkillSection) || inferSection(content)
5557
if (!section) {
56-
console.error('ERROR: Could not infer section type — use --section flag')
58+
console.error('Could not infer section type — use --section flag')
5759
process.exit(1)
5860
}
5961

0 commit comments

Comments
 (0)