Skip to content

Commit eecb31a

Browse files
committed
fix(amazonq): incorrect path for diff on windows
1 parent 975f0d0 commit eecb31a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/core/src/codewhisperer/util/zipUtil.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ export class ZipUtil {
122122
zip.addFile(zipEntryPath, Buffer.from(content, 'utf-8'))
123123

124124
if (scope === CodeWhispererConstants.CodeAnalysisScope.FILE_ON_DEMAND) {
125-
const gitDiffContent = `+++ b/${path.normalize(zipEntryPath)}` // Sending file path in payload for LLM code review
125+
const gitDiffContent = `+++ b/${path.normalize(zipEntryPath).replaceAll(path.win32.sep, path.posix.sep)}` // Sending file path in payload for LLM code review
126126
zip.addFile(ZipConstants.codeDiffFilePath, Buffer.from(gitDiffContent, 'utf-8'))
127127
}
128128
} else {

0 commit comments

Comments
 (0)