Skip to content

Commit 3240d29

Browse files
author
David Hasani
committed
zip sql metadata correctly
1 parent 1c3271a commit 3240d29

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

plugins/amazonq/codetransform/jetbrains-community/src/software/aws/toolkits/jetbrains/services/codemodernizer/model/CodeModernizerSessionContext.kt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -261,6 +261,10 @@ data class CodeModernizerSessionContext(
261261
dependencyFiles.forEach { depFile ->
262262
val relativePath = File(depFile.path).relativeTo(depDirectory)
263263
var relativePathString = relativePath.toPath().toString()
264+
if (copyResult == null) {
265+
// null copyResult means doing a SQL conversion; put metadata under dependencies folder
266+
relativePathString = File(ZIP_DEPENDENCIES_PATH).resolve(relativePath).toPath().toString()
267+
}
264268
// Convert Windows file path to work on Linux
265269
if (File.separatorChar != '/') {
266270
relativePathString = relativePathString.replace('\\', '/')

0 commit comments

Comments
 (0)