小编skp*_*aik的帖子

没有这样的字段:maven 类:org.jfrog.gradle.plugin.artifactory.dsl.PublisherConfig

我尝试使用 android studio 构建 java 库,并希望托管在我的本地工件上。我中午就遇到这个问题。尝试不同的代码,但没有改进。

buildscript {
repositories {
    jcenter()
}
repositories {
    maven {
        url 'http://localhost:8081/artifactory/libs-release-local'
        credentials {
            username = "${artifactory_user}"
            password = "${artifactory_password}"
        }
        name = "maven-main-cache"
    }
}
dependencies {
    classpath "org.jfrog.buildinfo:build-info-extractor-gradle:3.0.1"
}
}
project.getExtensions().getByName("ext")
apply plugin: 'scala'
apply plugin: 'maven-publish'
apply plugin: "com.jfrog.artifactory"

version = '1.0.0-SNAPSHOT'
group = 'com.buransky'

repositories {
    add buildscript.repositories.getByName("maven-main-cache")
}

dependencies {
    compile 'org.scala-lang:scala-library:2.11.2'
}

tasks.withType(ScalaCompile) {
    scalaCompileOptions.useAnt = false
}

artifactory {
    contextUrl = "${artifactory_contextUrl}"
    publish {
    repository {
        repoKey …
Run Code Online (Sandbox Code Playgroud)

gradle android-studio build.gradle android-gradle-plugin

2
推荐指数
1
解决办法
3254
查看次数