title: Importing Android Studio project to Intellij wrong gradle version
body: <p>I have a little problem with importing Android Studio Project to Intellij Idea 14.0.2 I'm using wrapper of version of gradle. I'm co-working on a project with my friend but he's working on Android Studio and i prefer Intellij Idea (i know it's propably almost the same, but i don't like having bunch of IDE's doing same job)... Any suggestions? Underneath is log from intellij</p>
  
  <pre><code>2014-12-23 13:27:20,243 [  94097]   INFO - s.plugins.gradle.GradleManager - Instructing gradle to use java from C:\Program Files\Java\jdk1.8.0_25 
  2014-12-23 13:27:20,248 [  94102]   INFO - s.plugins.gradle.GradleManager - Instructing gradle to use java from C:\Program Files\Java\jdk1.8.0_25 
  2014-12-23 13:27:20,271 [  94125]   INFO - .project.GradleExecutionHelper - Passing command-line args to Gradle Tooling API: [-Pandroid.injected.build.model.only=true, -Pandroid.injected.invoked.from.ide=true, --init-script, C:\Users\Hajto-Lenovo\AppData\Local\Temp\ijinit1.gradle] 
  2014-12-23 13:27:25,409 [  99263]  ERROR - vice.AndroidProjectDataService - Failed to set up Android modules in project 'LanceIt' 
  org.gradle.tooling.model.UnsupportedMethodException: Unsupported method: BaseArtifact.getJavaCompileTaskName().
  The version of Gradle you connect to does not support that method.
  To resolve the problem you can change/upgrade the target version of Gradle you connect to.
  Alternatively, you can ignore this exception and read other information from the model.
      at org.gradle.tooling.model.internal.Exceptions.unsupportedMethod(Exceptions.java:33)
      at org.gradle.tooling.internal.adapter.ProtocolToModelAdapter$InvocationHandlerImpl.invoke(ProtocolToModelAdapter.java:240)
      at com.sun.proxy.$Proxy136.getJavaCompileTaskName(Unknown Source)
      at org.jetbrains.android.facet.AndroidFacet.updateGradleTaskNames(AndroidFacet.java:1154)
      at org.jetbrains.android.facet.AndroidFacet.syncSelectedVariant(AndroidFacet.java:1145)
      at com.android.tools.idea.gradle.customizer.android.AndroidFacetModuleCustomizer.configureFacet(AndroidFacetModuleCustomizer.java:96)
      at com.android.tools.idea.gradle.customizer.android.AndroidFacetModuleCustomizer.customizeModule(AndroidFacetModuleCustomizer.java:56)
      at com.android.tools.idea.gradle.customizer.android.AndroidFacetModuleCustomizer.customizeModule(AndroidFacetModuleCustomizer.java:42)
      at com.android.tools.idea.gradle.service.AndroidProjectDataService.customizeModule(AndroidProjectDataService.java:191)
      at com.android.tools.idea.gradle.service.AndroidProjectDataService.access$100(AndroidProjectDataService.java:64)
      at com.android.tools.idea.gradle.service.AndroidProjectDataService$1.run(AndroidProjectDataService.java:126)
      at com.intellij.openapi.command.WriteCommandAction$Simple.run(WriteCommandAction.java:166)
      at com.intellij.openapi.application.RunResult.run(RunResult.java:38)
      at com.intellij.openapi.command.WriteCommandAction$2$1.run(WriteCommandAction.java:114)
      at com.intellij.openapi.application.impl.ApplicationImpl.runWriteAction(ApplicationImpl.java:974)
      at com.intellij.openapi.command.WriteCommandAction$2.run(WriteCommandAction.java:111)
      at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:124)
      at com.intellij.openapi.command.impl.CoreCommandProcessor.executeCommand(CoreCommandProcessor.java:99)
      at com.intellij.openapi.command.WriteCommandAction.performWriteCommandAction(WriteCommandAction.java:108)
      at com.intellij.openapi.command.WriteCommandAction.execute(WriteCommandAction.java:80)
      at com.android.tools.idea.gradle.service.AndroidProjectDataService.doImport(AndroidProjectDataService.java:114)
      at com.android.tools.idea.gradle.service.AndroidProjectDataService.importData(AndroidProjectDataService.java:97)
      at com.intellij.openapi.externalSystem.service.project.manage.ProjectDataManager.importData(ProjectDataManager.java:116)
      at com.intellij.openapi.externalSystem.service.project.manage.ProjectDataManager.importData(ProjectDataManager.java:98)
      at com.intellij.openapi.externalSystem.service.project.manage.ProjectDataManager.importData(ProjectDataManager.java:124)
      at com.android.tools.idea.gradle.project.ProjectSetUpTask$2$1$1.run(ProjectSetUpTask.java:117)
      at com.intellij.openapi.roots.impl.ProjectRootManagerImpl.mergeRootsChangesDuring(ProjectRootManagerImpl.java:325)
      at com.android.tools.idea.gradle.project.ProjectSetUpTask$2$1.execute(ProjectSetUpTask.java:112)
      at com.intellij.openapi.externalSystem.util.DisposeAwareProjectChange.run(DisposeAwareProjectChange.java:36)
      at com.intellij.openapi.externalSystem.util.ExternalSystemApiUtil$6$1.run(ExternalSystemApiUtil.java:374)
      at com.intellij.openapi.application.impl.ApplicationImpl.runWriteAction(ApplicationImpl.java:974)
      at com.intellij.openapi.externalSystem.util.ExternalSystemApiUtil$6.run(ExternalSystemApiUtil.java:371)
      at com.intellij.util.ui.UIUtil.invokeLaterIfNeeded(UIUtil.java:2108)
      at com.intellij.openapi.externalSystem.util.ExternalSystemApiUtil.executeOnEdt(ExternalSystemApiUtil.java:391)
      at com.intellij.openapi.externalSystem.util.ExternalSystemApiUtil.executeProjectChangeAction(ExternalSystemApiUtil.java:369)
      at com.intellij.openapi.externalSystem.util.ExternalSystemApiUtil.executeProjectChangeAction(ExternalSystemApiUtil.java:365)
      at com.android.tools.idea.gradle.project.ProjectSetUpTask$2.run(ProjectSetUpTask.java:109)
      at com.intellij.ide.startup.impl.StartupManagerImpl$8.run(StartupManagerImpl.java:329)
      at com.intellij.ide.startup.impl.StartupManagerImpl$9.run(StartupManagerImpl.java:340)
      at com.intellij.util.ui.UIUtil.invokeLaterIfNeeded(UIUtil.java:2108)
      at com.intellij.ide.startup.impl.StartupManagerImpl.runWhenProjectIsInitialized(StartupManagerImpl.java:337)
      at com.android.tools.idea.gradle.project.ProjectSetUpTask.populateProject(ProjectSetUpTask.java:106)
      at com.android.tools.idea.gradle.project.ProjectSetUpTask.access$000(ProjectSetUpTask.java:46)
      at com.android.tools.idea.gradle.project.ProjectSetUpTask$1.run(ProjectSetUpTask.java:68)
      at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:311)
      at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:744)
      at java.awt.EventQueue.access$400(EventQueue.java:97)
      at java.awt.EventQueue$3.run(EventQueue.java:697)
      at java.awt.EventQueue$3.run(EventQueue.java:691)
      at java.security.AccessController.doPrivileged(Native Method)
      at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:75)
      at java.awt.EventQueue.dispatchEvent(EventQueue.java:714)
      at com.intellij.ide.IdeEventQueue.e(IdeEventQueue.java:748)
      at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:577)
      at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:384)
      at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:201)
      at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
      at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
      at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
      at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
      at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)
  2014-12-23 13:27:25,410 [  99264]  ERROR - vice.AndroidProjectDataService - IntelliJ IDEA 14.0.2  Build #IU-139.659.2 
  2014-12-23 13:27:25,410 [  99264]  ERROR - vice.AndroidProjectDataService - JDK: 1.8.0_25 
  2014-12-23 13:27:25,410 [  99264]  ERROR - vice.AndroidProjectDataService - VM: Java HotSpot(TM) Server VM 
  2014-12-23 13:27:25,410 [  99264]  ERROR - vice.AndroidProjectDataService - Vendor: Oracle Corporation 
  2014-12-23 13:27:25,411 [  99265]  ERROR - vice.AndroidProjectDataService - OS: Windows 7 
  2014-12-23 13:27:25,766 [  99620]   INFO - indexing.UnindexedFilesUpdater - Indexable files iterated in 21 ms 
  </code></pre>
  
  <p>And gradle files:</p>
  
  <pre><code>apply plugin: 'com.android.application'
  
  android {
      compileSdkVersion 21
      buildToolsVersion "21.1.2"
  
      defaultConfig {
          applicationId "myAppID"
          minSdkVersion 15
          targetSdkVersion 21
          versionCode 1
          versionName "1.0"
      }
      buildTypes {
          release {
              minifyEnabled false
              proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
          }
      }
  }
  
  dependencies {
      compile fileTree(dir: 'libs', include: ['*.jar'])
      compile 'com.android.support:appcompat-v7:21.0.3'
      compile 'com.google.android.gms:play-services:6.1.71'
      compile 'com.mcxiaoke.volley:library:1.0.+'
      compile project(':swipeToDismissUndoListmaster')
  }
  </code></pre>
  
  <p>And props:</p>
  
  <pre><code>buildscript {
      repositories {
          jcenter()
      }
      dependencies {
          classpath 'com.android.tools.build:gradle:1.0.0'
      }
  }
  
  allprojects {
      repositories {
          jcenter()
      }
  }
  </code></pre>
  
  <p>Gradle-wrapper.properties:</p>
  
  <pre><code>#Wed Apr 10 15:27:10 PDT 2013
  distributionBase=GRADLE_USER_HOME
  distributionPath=wrapper/dists
  zipStoreBase=GRADLE_USER_HOME
  zipStorePath=wrapper/dists
  distributionUrl=https\://services.gradle.org/distributions/gradle-2.2.1-all.zip
  </code></pre>