File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -53,6 +53,9 @@ const generateTemplatesCommand = defineCommand({
5353 } ,
5454 } ,
5555 run : async ( { args } ) => {
56+ if ( args . debug ) consola . level = Number . MAX_SAFE_INTEGER ;
57+ if ( args . silent ) consola . level = 0 ;
58+
5659 await generateTemplates ( {
5760 cleanOutput : args [ "clean-output" ] ,
5861 httpClientType : args [ "http-client" ] ,
@@ -270,6 +273,9 @@ const generateCommand = defineCommand({
270273 } ,
271274 } ,
272275 run : async ( { args } ) => {
276+ if ( args . debug ) consola . level = Number . MAX_SAFE_INTEGER ;
277+ if ( args . silent ) consola . level = 0 ;
278+
273279 let customConfig = null ;
274280 let customConfigPath : string | undefined ;
275281
Original file line number Diff line number Diff line change 1- import { consola } from "consola" ;
21import type { GenerateApiConfiguration } from "../types/index.js" ;
32import { CodeGenProcess } from "./code-gen-process.js" ;
43
54export async function generateApi (
65 config : Partial < GenerateApiConfiguration [ "config" ] > ,
76) {
8- if ( config . debug ) {
9- consola . level = Number . MAX_SAFE_INTEGER ;
10- }
117 const codeGenProcess = new CodeGenProcess ( config ) ;
128 return await codeGenProcess . start ( ) ;
139}
You can’t perform that action at this time.
0 commit comments