Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion packages/svelte-check/src/options.ts
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,14 @@ const outputFormats = ['human', 'human-verbose', 'machine', 'machine-verbose'] a
type OutputFormat = (typeof outputFormats)[number];

function getOutputFormat(opts: Record<string, any>): OutputFormat {
return outputFormats.includes(opts.output) ? opts.output : 'human-verbose';
if (outputFormats.includes(opts.output)) {
return opts.output;
} else if (process.env.CLAUDECODE === '1') {
// https://github.com/sveltejs/language-tools/issues/2868
return 'machine';
} else {
return 'human-verbose';
}
}

function getWorkspaceUri(opts: Record<string, any>) {
Expand Down