Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow Android Studio to run with Skate with runLocalIde #1243

Merged
merged 5 commits into from
Feb 28, 2025

Conversation

kateliu20
Copy link
Contributor

@kateliu20 kateliu20 commented Feb 27, 2025

Currently, running ./gradlew :platforms:intellij:skate:runIde opens up a new instance of IntelliJ to test the plugin.

Because some things like Markdown rendering are different in Android Studio and IntelliJ, I set up a way to run Studio locally with runLocalIde. This will save time so we don't have to build the plugin and install the zip on AS to test our Skate changes.

I added this line to my ~/.gradle/gradle.properties file:
intellijPlatformTesting.idePath=/Users/liu.k/Applications/Android Studio.app

Now, ./gradlew :platforms:intellij:skate:runLocalIde will open Android Studio.

Discussion.

@@ -39,6 +39,9 @@ ksp.useKSP2=true
# https://github.com/JetBrains/intellij-platform-gradle-plugin/blob/33af9bdd1d0d8b996b911781ab23013dd14997f4/src/main/kotlin/org/jetbrains/intellij/platform/gradle/GradleProperties.kt#L104C12-L104C27
org.jetbrains.intellij.platform.SelfUpdateCheck=false

# We can now run ./gradlew runLocalIde on Android Studio, so we have test more comprehensively with Skate
intellijPlatformTesting.idePath=/Applications/Android Studio.app/Contents
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

talked offline but let's make this something developers specify locally in their home ~/.gradle/gradle.properties and document it in the skate docs

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done here: 6c7dc58

I added this line to my ~/.gradle/gradle.properties file:
intellijPlatformTesting.idePath=/Users/liu.k/Applications/Android Studio.app and was able to run the task from CLI.

1. Build local version of the plugin with `./gradlew buildPlugin`
2. Open IDE settings, then "Install Plugin from Disk..."

#### Local testing from CLI
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd call this "Local testing with runLocalIde" since this command can be run from the IDE too

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good, 2353c30

kateliu20 and others added 2 commits February 28, 2025 14:08
Co-authored-by: Zac Sweers <pandanomic@gmail.com>
@kateliu20 kateliu20 added this pull request to the merge queue Feb 28, 2025
Merged via the queue into main with commit ec8a4e0 Feb 28, 2025
4 checks passed
@kateliu20 kateliu20 deleted the kl/setup_runLocalIde branch February 28, 2025 19:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants