You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: plugins/amazonq/codetransform/jetbrains-community/src/software/aws/toolkits/jetbrains/services/codemodernizer/CodeModernizerManager.kt
Copy file name to clipboardExpand all lines: plugins/amazonq/codetransform/jetbrains-community/src/software/aws/toolkits/jetbrains/services/codemodernizer/controller/CodeTransformChatController.kt
Copy file name to clipboardExpand all lines: plugins/amazonq/codetransform/jetbrains-community/src/software/aws/toolkits/jetbrains/services/codemodernizer/utils/CodeTransformModuleUtils.kt
Copy file name to clipboardExpand all lines: plugins/amazonq/codetransform/jetbrains-community/src/software/aws/toolkits/jetbrains/services/codemodernizer/utils/CodeTransformProjectUtils.kt
+5-5Lines changed: 5 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -79,15 +79,15 @@ fun Project.getSupportedModules(supportedJavaMappings: Map<JavaSdkVersion, Set<J
79
79
moduleJdk in supportedJavaMappings
80
80
}
81
81
82
-
// return the first file or directory found inside each open Java module, so that user can select a Module for us to ZIP
83
-
fun Project.getJavaModules() =this.modules.flatMap { module ->
82
+
// return the first file or directory found inside each open Java module that contains SQL statements, so that user can select a Module for us to ZIP
83
+
fun Project.getJavaModulesWithSQL() =this.modules.flatMap { module ->
84
84
val rootManager =ModuleRootManager.getInstance(module)
85
85
if (rootManager.sdk?.sdkType?.name?.lowercase()?.contains("java") ==true) {
86
86
val contentRoots = rootManager.contentRoots
87
87
if (contentRoots.isNotEmpty()) {
88
-
valfirstContentRoot= contentRoots.first()
89
-
val children =firstContentRoot.children
90
-
if (children.isNotEmpty()) {
88
+
valcontentRoot= contentRoots.first()
89
+
val children =contentRoot.children
90
+
if (children.isNotEmpty()&& containsSQL(contentRoot)) {
0 commit comments