File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -6,6 +6,7 @@ import { TemplatesGenConfig } from "./src/commands/generate-templates/configurat
66import { CodeGenConfig } from "./src/configuration.js" ;
77import { HTTP_CLIENT } from "./src/constants.js" ;
88import { generateApi , generateTemplates } from "./src/index.js" ;
9+ import { pathToFileURL } from "url" ;
910
1011const templateGenBaseConfig = new TemplatesGenConfig ( { } ) ;
1112
@@ -282,7 +283,7 @@ const generateCommand = defineCommand({
282283 if ( args [ "custom-config" ] ) {
283284 try {
284285 customConfigPath = path . resolve ( process . cwd ( ) , args [ "custom-config" ] ) ;
285- customConfig = await import ( customConfigPath ) ;
286+ customConfig = await import ( pathToFileURL ( customConfigPath ) . toString ( ) ) ;
286287 customConfig = customConfig . default || customConfig ;
287288 } catch ( error ) {
288289 consola . error ( "Error loading custom config:" , error ) ;
You can’t perform that action at this time.
0 commit comments