简体   繁体   中英

Axion Release Plugin Error on Gradle Build

I've been struggling to build an Android lib and publish it to Azure Devops Artifacts using Gradle.

I finally published it yesterday, and today I came across the need to version it automatically, so I'm trying to use this plugin: https://plugins.gradle.org/plugin/pl.allegro.tech.build.axion-release
https://axion-release-plugin.readthedocs.io/en/latest/

So, making it shorter, I'm simply not able to apply the plugin, I'm not even using it, just applied it, and it breaks instantly.

Any ideas on the reason?

I applied it based on this:

buildscript {
  repositories {
    maven {
      url "https://plugins.gradle.org/m2/"
    }
  }
  dependencies {
    classpath "pl.allegro.tech.build:axion-release-plugin:1.11.0"
  }
}

apply plugin: "pl.allegro.tech.build.axion-release" version '1.11.0'

The error I'm getting is this:

org.gradle.api.GradleScriptException: A problem occurred evaluating root project 'core'.

* What went wrong:
A problem occurred evaluating root project 'core'.
> Cannot invoke method version() on null object

Ok, it was the version info in the: apply plugin: "pl.allegro.tech.build.axion-release" version '1.11.0'

Using: apply plugin: "pl.allegro.tech.build.axion-release"

It works.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM