Skip to content

Commit 3cc6e6e

Browse files
committed
support plugin downgrade in ui versioning
1 parent 6ba2d59 commit 3cc6e6e

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

ide-common/src/main/kotlin/org/digma/intellij/plugin/paths/DigmaPathManager.kt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,19 +20,25 @@ class DigmaPathManager {
2020
private val logger = Logger.getInstance(this::class.java)
2121

2222
/**
23-
* returns the base directory to save files belonging to digma installation
23+
* returns the base directory to save files belonging to digma installation.
24+
* it will return the directory path for the current running IDE.
25+
* the path is made of '$USER_HOME/$DIGMA_DIR/$IDE_NAME'
2426
*/
2527
fun getLocalFilesDirectoryPath(): String {
2628

2729
Log.log(logger::trace, "getLocalFilesDirectoryPath called")
2830

31+
//ideName should be unique per ide installation. it will be the name of a sub folder of the
32+
// user's base directory for digma.
2933
val ideName = createIdeName()
3034

3135
return try {
36+
//baseDir is the base directory for digma that should return the same directory in every IDE. it's a per-user directory.
3237
val baseDir = getBaseDirectory()
3338
val ideDir = File(baseDir, ideName)
3439
ideDir.mkdirs()
3540
Log.log(logger::trace, "getLocalFilesDirectoryPath created ide dir {}", ideDir.absolutePath)
41+
//ide.info file is just for info, user can check it to see which IDE this folder belongs to.
3642
val ideInfo = File(ideDir, "ide.info")
3743
if (!ideInfo.exists()) {
3844
val ideInfoText =

0 commit comments

Comments
 (0)