-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #108 from pontem-network/1.30.0
1.30.0
- Loading branch information
Showing
55 changed files
with
1,514 additions
and
179 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# INTELLIJ MOVE CHANGELOG: 1.30.0 | ||
|
||
17 Jul 2023 | ||
|
||
## Features | ||
|
||
* Add "Download Aptos" button to the Move settings. | ||
|
||
* Address validation in the `Move.toml` file. | ||
|
||
* Function naming inspection. | ||
|
||
* Highlight resources and mutable references in the code. | ||
|
||
* Support underscores in integer and hex literals ([#107](https://github.com/pontem-network/intellij-move/issues/107)). | ||
|
||
## Fixes | ||
|
||
* More fixes for dot expr type inference. | ||
|
||
## Internal | ||
|
||
* Add `[dependencies]` and library path to the Sentry diagnostics. It will hopefully allow to fix issues with the dependency paths. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
distributionBase=GRADLE_USER_HOME | ||
distributionPath=wrapper/dists | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-7.6-bin.zip | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.2-bin.zip | ||
zipStoreBase=GRADLE_USER_HOME | ||
zipStorePath=wrapper/dists |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
58 changes: 58 additions & 0 deletions
58
src/main/kotlin/org/move/cli/sentryReporter/SentryContextsProjectsListener.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
package org.move.cli.sentryReporter | ||
|
||
import io.sentry.Sentry | ||
import org.move.cli.MoveProject | ||
import org.move.cli.MoveProjectsService | ||
import org.move.cli.MoveProjectsService.MoveProjectsListener | ||
import org.move.cli.manifest.TomlDependency | ||
import org.move.openapiext.getTable | ||
import org.move.openapiext.getTablesByFirstSegment | ||
import org.move.openapiext.syntheticLibraries | ||
|
||
@Suppress("PropertyName") | ||
private data class MoveTomlContext( | ||
val name: String, | ||
val dependencies_parsed: List<TomlDependency>, | ||
val dependencies_raw: List<String>, | ||
) | ||
|
||
private data class SyntheticLibraryContext(val roots: List<String>) | ||
|
||
private data class MoveProjectContext( | ||
val moveToml: MoveTomlContext, | ||
val syntheticLibraries: List<SyntheticLibraryContext> | ||
) | ||
|
||
class SentryContextsProjectsListener : MoveProjectsListener { | ||
override fun moveProjectsUpdated(service: MoveProjectsService, projects: Collection<MoveProject>) { | ||
Sentry.configureScope { | ||
it.setContexts( | ||
"projects", | ||
projects.mapNotNull { moveProject -> getMoveProjectContext(moveProject) } | ||
) | ||
} | ||
} | ||
|
||
private fun getMoveProjectContext(moveProject: MoveProject): MoveProjectContext? { | ||
val tomlFile = moveProject.currentPackage.moveToml.tomlFile ?: return null | ||
|
||
val rawDeps = mutableListOf<String>() | ||
val depsTable = tomlFile.getTable("dependencies") | ||
if (depsTable != null) { | ||
rawDeps.add(depsTable.text) | ||
} | ||
for (depInlineTable in tomlFile.getTablesByFirstSegment("dependencies")) { | ||
rawDeps.add(depInlineTable.text) | ||
} | ||
|
||
val moveTomt = MoveTomlContext( | ||
name = moveProject.currentPackage.packageName, | ||
dependencies_raw = rawDeps, | ||
dependencies_parsed = moveProject.currentPackage.moveToml.deps.map { it.first }, | ||
) | ||
val syntheticLibraries = | ||
moveProject.project.syntheticLibraries | ||
.map { SyntheticLibraryContext(it.allRoots.map { it.path }) } | ||
return MoveProjectContext(moveTomt, syntheticLibraries) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.