Skip to content

Commit e2083fa

Browse files
committed
fix: add rust client
1 parent 0879e7e commit e2083fa

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

packages/cli/src/commands/init.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -140,13 +140,13 @@ function getContentFromPromptResult(result: PromptResult, configFileType: Config
140140
if (configFileType == 'json') {
141141
return JSON.stringify(content, null, 4);
142142
} else if (configFileType == 'gill') {
143-
return (
144-
`import { createCodamaConfig } from "gill";\n\n` +
143+
return `import { createCodamaConfig } from "gill";\n\n` +
145144
`export default createCodamaConfig({ \n\t` +
146145
`idl: "${result.idlPath}", \n\t` +
147146
`clientJs: "${result.jsPath}", \n` +
148-
`});`
149-
);
147+
result.scripts.includes('rust')
148+
? `clientRust: "${result.rustPath}", \n`
149+
: `` + `});`;
150150
}
151151

152152
return (

0 commit comments

Comments
 (0)