0
votes

I found a salesforce plugin for intellij IDEA (link), and now trying to install it. The problem is, i've never done this before. So according to instruction:

How to build and install

Until the plugin is released into the IntelliJ plugins repository, you can following these instructions for manually building and installing the plugin from GitHub:

  1. Update the ANT script salesforce-plugin-xml with the location of your IntelliJ IDEA install <!--property name="idea.path" value="C:\Program Files (x86)\JetBrains\IntelliJ IDEA 13.0.2"/--> <property name="idea.path" value="/Applications/IntelliJ IDEA 13.app"/>
  2. Execute the 'package' target of the ANT script - this will create a salesforce-plugin-#.#.zip file in the out directory
  3. Go into IntelliJ IDEA settings under Plugins and select "Install plugin from disk". Select the zip file and click Ok.

I downloaded a project from github, added path to idea to salesforce-plugin.xml. Then i realized that i don't have an ant to build it. I installed homebrew, installed ant, checked the version (ant appeared, ok). Then i stuck. I tried different combinations, how to package the plugin, The last attempt is when i changed salesforce-plugin.xml to build.xml and wrote in terminal:

ant package build.xml

got:

Buildfile: /Users/cooler/Downloads/salesforce-plugin-master/build.xml

BUILD FAILED /Users/cooler/Downloads/salesforce-plugin-master/build.xml:36: taskdef class com.intellij.ant.Javac2 cannot be found using the classloader AntClassLoader[]

Can you help me please to do this in right way!?

BTW, i use Mavericks

2

2 Answers

2
votes

On a Mac, you need to add /Contents to the root path of the IDEA installation. For example:

<property name="idea.path" value="/Applications/IntelliJ IDEA 14.app/Contents"/>
1
votes

When generating ant build scripts:

build -> generate ant build 
-> check "use current idea instance for idea.home property"

Re-generate the ant build scripts. Now the build should work propertly.