无法获得未知 属性 'publishableFiles'

Could not get unknown property 'publishableFiles'

尝试发布到 bintray 时出现以下错误。

FAILURE: Build completed with 2 failures.

1: Task failed with an exception.
-----------
* What went wrong:
Execution failed for task ':bintrayUpload'.
> Could not get unknown property 'publishableFiles' for object of type org.gradle.api.publish.maven.internal.publication.DefaultMavenPublication.

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
==============================================================================

2: Task failed with an exception.
-----------
* What went wrong:
Execution failed for task ':bintrayPublish'.
> Could not publish 'messai/maven/kyuga/0.0.6': HTTP/1.1 404 Not Found [message:Version '0.0.6' was not found]

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
==============================================================================

* Get more help at https://help.gradle.org

BUILD FAILED in 2s

我的项目是一个 kotlin 多平台项目,以下是 gradle 中的发布设置:

publishing {
    repositories {
        maven {
            url  = project.projectBintrayRepo
        }
    }

    publications {
        mavenProject(MavenPublication) {
            groupId project.groupId
            artifactId project.projectBintrayArtifactName
            version project.kyugaVersion
            withPom(pom)
        }
    }
}

请帮忙

  1. 您的项目中的某些东西正在尝试从 MavenPublication 中获取 publishableFiles 属性。如错误所示,不存在这样的 属性。
  2. 看起来您正在尝试发布到不存在的存储库,因此 404 Not Found。您需要发布到现有的存储库。