Android Studio - Configure local paths - ide

I'm currently struggling to get Android Studio running on my windows box. The problem seems to be that I moved my home-directory to a different drive than C. (Because I have a tiny SSD for the system only and the rest is on my HDD)
I changed the gradle settings from android studio to the correct folder on drive E but when I try to create a new project this error pops up:
Failed to import Gradle project: Could not install Gradle distribution from 'http://services.gradle.org/distributions/gradle-1.6-bin.zip'. java.io.FileNotFoundException: C:\Users\myuser\.gradle\wrapper\dists\gradle-1.6-bin etc.
I need the IDE to download it to E:\Users\myuser\etc.
Any idea where I can configure that? The settings from the settings dialog seem to be ignored.

it happens from time to time when gradle server has a bad day. Usually when they publish new version.

Related

JAVAFX Build Fails with Intellij on MAC

I have been trying to complete this step for 2 days and can't find a solution.
I am running IntelliJ on Mac 10.13.2
After creating a brand new project with nothing more than the "Hello World" Title screen I attempt to build artifacts.
I have my project settings correct for what I can tell and set the output to be native dmg.
the error I get is:
Error:Java FX Packager:
BUILD FAILED
/Users/silverapple/Library/Caches/IdeaIC2017.3/compile-server/asi-sync_34d86456/_temp_/build.xml:29: Error: Bundler "DMG Installer" (dmg) failed to produce a bundle.
Total time: 1 minute 13 seconds
Error:Java FX Packager: Buildfile: /Users/silverapple/Library/Caches/IdeaIC2017.3/compile-server/asi-sync_34d86456/_temp_/build.xml
build artifact:
No base JDK. Package will use system JRE.
No base JDK. Package will use system JRE.
Building DMG package for JavaFXApp
Error:Java FX Packager: fx:deploy task has failed.
I have googled up and down and can not figure out why I can not get a build.
The weird thing is that this process produces a mounted dmg package on the desktop that runs fine. But nothing in the build folder.
Jan 17th, 2018
Posting the work around I found here as it may not be obvious to some. It wasn't to me as a Mac Noob who thought a dmg build was the only way to go.
This is a known issue and can be tracked here...
If you specify "img" as the native bundle in IntelliJ Project Settings you will get an .app package in the build folder.
The user can copy this to the Application folder and run it from there.
NOTE: For me the app was un-signed so it was blocked by GateKeeper. Command click allowed me to open it and set it to a trusted app.

IntelliJ Run Configuration Broken by an Incompatible Plugin I Can't Uninstall?

I had been developing an application on a trial version of IntelliJ 2016 Ultimate. Since the trial version ran out, I resumed work using the Community Edition. However, trying to launch my application yielded the following error:
Unknown run configuration type #com.intellij.j2ee.web.tomcat.TomcatRunConfigurationFactory
"No problem" I thought, just an incompatible plugin that was installed with Ultimate that I don't really need anyway. I opened the Plugins section of the Preferences menu, but I can't find the plugin in question. Below is a partial screenshot of the plugin list where I would expect to see the plugin listed in the error message.
The configuration can also not be edited from the Run/Debug Configurations menu, but lists the Run Configuration error as: "Broken configuration due to unavailable plugin or invalid configuration data."
Am I really unable to uninstall the Ultimate plugin preventing my run configuration from working from the Community Edition? What can I do to fix this if so?
It's have been a long time since this question was launched but it might be useful for new searches.
I got the same error with Dart and Flutter.
Just go to Menu >> File >> Settings. Then type plugins on the search box. Check if your plugins need to be updated (in my case Dart and Flutter). I the screenshot I had clicked in the "update" green button. So it turns into "Restart IDE" text. It should fix the problem once you restart the IDE.
To the best of my knowledge the community edition of IDEA will not load and run plugins that are not compatible with it. Moreover, by default, the community edition uses a different configuration directory than the Ultimate edition. So unless you modified the config directory to use, the community version should not be picking up the Ultimate Edition's plugins. Based on the error you show, I think the issue is you simply need to delete that Run configuration. The error is saying that that Run configuration wants to use a Plugin (The Tomcat Plugin) that is not available (i.e. not installed).
If you still want to confirm what plugins are installed, you can manually uninstall a plugin by removing it from the plugins directory. Note that some plugins are simply a standalone JAR, in the plugins directory, others are sub-directories within the plugins directory. Just delete the JAR or sub-directory.
That plugins directory is the idea config directory. See Directories used by the IDE to store settings, caches, plugins and logs for information on its location. On windows for example, by default it will be:
Ultimate: C:\Users\UserName\.IntelliJIdea2016\config\plugins
Community: C:\Users\UserName\..IdeaIC2016\config\plugins
UPDATE
I forgot to mention... bundled plugins are in ${idea-install-directory}/plugins. So for the ultimate edition, the Tomcat plugin is in ${idea-install-directory}/plugins/Tomcat. That is why, as you mentioned in your comment below, you are not seeing that plugin in the user installed plugin directory I mentioned above.
updating flutter and android studio worked in my
case
Simple upgrade Dart plugin..
Go to Settings/Plugins/Browse Repositories and search dart (Language) and upgrade
this will work.
I had a similar worded issue "Run Configuration Error: Broken configuration due to unavailable plugin or invalid configuration data."
In the bottom right part of the Rider IDE, you will see a popup that says
"Plugin supporting feature (Run Configuration[UNITY_ATTACH_AND_PLAY]) is currently disabled."
Click enable plugins, and restart when Rider asks you to do so.
If this does not work, remember that one possible reason is the issues with macOS indexing (my Macbook started to malfunction after its battery hit 0). A way to check is to try and search a file from the top right corner(). If you can not find existing files, this means macOS messed up with indexing.
To solve it, click Apple icon on top left side and go to System Preferences -> Spotlight -> Privacy Tab -> Add all folders to the "won't index" box -> Remove everything you have added so they get reindexed.
https://www.techradar.com/how-to/software/operating-systems/how-to-fix-a-mac-s-broken-find-function-1298964
Lastly, go to Rider and hit File -> Invalidate Caches and Restart.

Run intellij plugin on Android Studio

I'm developing an intellij plugin supposed to be used in android studio.
I've already setup the plugin development environment, but when I hit "Run" command it starts a new intellij instance with the plugin installed.
What I'm looking for is how to run the plugin directly on Android Studio, is that possibile? The only place where I think it can be configured is from "Run configurations" but I do not find anything useful there.
Thanks
You can specify the platform to run on in the IntelliJ Platform Plugin SDK settings, under Platform Settings | SDKs in the Project Structure settings. Point the IntelliJ Platform Plugin SDK home path to your Android Studio installation.
Another option is to create a new Plugin Run Configuration. In the Run Configuration it is possible to specify the JRE to run on. Click on the ... button there and select an Android Studio installation directory (e.g. /Applications/Android Studio.app/Contents on the Mac). This way it is possible to create a Run Configuration for all IntelliJ Platform IDEs you want to test your plugin on.

Can not import libgdx project to Intellij IDEA 14

I want to import libgdx project to Intellij IDEA 14 with gradle 2.4. But I can not do. Because when I try to import, Intellij gives error that "resolve error, Already created an SDK Loader with different SDK Path".
I set sdk.dir in local.proporties file. Also I did not set ANDROID_HOME in path.
How can I proceed?
I had the same problem. I wonder if it was caused by using IntelliJ after using Android Studio on the same machine? I got rid of this problem by deleting ~/.gradle but I think that caused other problems, because the libgdx project wouldn't build the desktop module before running it, then kept hanging with high CPU load when I clicked the build button. I ran the project's gradlew in a terminal to see what would happen, and it downloaded a new zip of gradle and seems to have fixed the problem.

IBM Worklight v6.0 - Error while adding an application to the Mobile Test Workbench

I have a Worklight app, created an apk file from it. Created a Test Project.
Adding the apk file to the workbench, it has an error saying:
Application xxx.apk cannot be imported; it is either an invalid one or
it contains specific features that are not supported.
Try opening the .log file for the worklight workspace. I saw an error saying that for the Rational Test Workbench to work, I need to use JDK and not JRE.
The solution that solves my problem is as follow:
In the workspace, go to Window > Preferences
Expand Java > Installed JREs
Add a new JDK and ticky mark it
Open the xxx.ma file
You should still see the error in that file
Select the mobile app from the test workbench file. Delete it
Add the mobile app again to the test workbench file. It will take some time to process.
The problem is most likely to do with the fact that your Eclipse is not pointing to a JDK.
Please edit eclipse.ini to point to your JDK (-vm ... jdk location...)