Skip to content

Commit c1a1f4f

Browse files
authored
Merge pull request #68 from thedadams/exe-windows-binary
fix: append '.exe' to binary on Windows
2 parents 10706b1 + 6f3d8ea commit c1a1f4f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/gptscript.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ export interface RunOpts {
3737
chatState?: string
3838
confirm?: boolean
3939
prompt?: boolean
40-
credentialOverride?: string
40+
credentialOverride?: string
4141
env?: string[]
4242

4343
APIKey?: string
@@ -802,7 +802,7 @@ function getCmdPath(): string {
802802
return process.env.GPTSCRIPT_BIN
803803
}
804804

805-
return path.join(path.dirname(fileURLToPath(import.meta.url)), "..", "bin", "gptscript")
805+
return path.join(path.dirname(fileURLToPath(import.meta.url)), "..", "bin", "gptscript" + (process.platform === "win32" ? ".exe" : ""))
806806
}
807807

808808
function parseBlocksFromNodes(nodes: any[]): Block[] {

0 commit comments

Comments
 (0)