[转载]使用gradle开发intellij idea plugin插件遇到的问题

引用:Gradle依赖项学习总结,dependencies、transitive、force、exclude的使用与依赖冲突解决

统一加载gradle的项目依赖

buildscript {
    repositories {
        mavenCentral()
        maven {
            url "https://oss.sonatype.org/content/repositories/snapshots/"
        }
        maven {
            url 'http://dl.bintray.com/jetbrains/intellij-plugin-service'
        }

    }
    dependencies {
        classpath "org.jetbrains.intellij.plugins:gradle-intellij-plugin:0.3.0-SNAPSHOT"
    }
}


apply plugin: 'org.jetbrains.intellij'
apply plugin: 'java'
intellij {
    version 'IU-172.4155.36'
    plugins = ['JavaScriptLanguage', 'CSS']
    pluginName 'AJX_IDE_plugin'
}

添加的其他依赖库会有重复依赖的org.slf4j:slf4j-api:1.7.7的包重复依赖

build.gradle中添加exclude

configurations {
    all*.exclude group: 'org.slf4j'
}

你可能感兴趣的:([转载]使用gradle开发intellij idea plugin插件遇到的问题)