Giter Site home page Giter Site logo

Comments (4)

thebignet avatar thebignet commented on August 15, 2024

Apparently, it should be located at https://plugins.gradle.org/m2/. Try to add this maven repository to your configuration.

from swagger-codegen-gradle-plugin.

RobMcA avatar RobMcA commented on August 15, 2024

So I tried the following configuration:

dependencies {
  repositories {
    maven {
      url "https://plugins.gradle.org/m2/"
    }
  }
  // Swagger
  compile "org.detoeuf:swagger-codegen-plugin:1.6.3"
}

and got this result:

FAILURE: Build failed with an exception.

* What went wrong:
A problem occurred configuring root project 'amp-gradle-plugin'.
> Could not resolve all dependencies for configuration ':classpath'.
   > Could not find org.detoeuf:swagger-codegen-plugin:1.6.3.
     Searched in the following locations:
         https://plugins.gradle.org/m2/org/detoeuf/swagger-codegen-plugin/1.6.3/swagger-codegen-plugin-1.6.3.pom
         https://plugins.gradle.org/m2/org/detoeuf/swagger-codegen-plugin/1.6.3/swagger-codegen-plugin-1.6.3.jar
     Required by:
         project :

But if I pull down the repo and do ./gradlew install and add mavenLocal() to my dependency list, it resolves fine.

So perhaps publishing the plugin to https://plugins.gradle.org/m2 does not make the compilation unit available, and it can only be referenced as a plugin?

from swagger-codegen-gradle-plugin.

RobMcA avatar RobMcA commented on August 15, 2024

I think I've found it. When plugins are published to https://plugins.gradle.org/m2, their group name is prefixed with gradle.plugin. So for resolving the compilation unit, you have to use gradle.plugin.org.detoeuf:swagger-codegen-plugin:1.6.3.

You might want to publish the compilation unit on maven central and/or jcenter so other who want a compile-time dependency can reference the library.

from swagger-codegen-gradle-plugin.

thebignet avatar thebignet commented on August 15, 2024

I think gradle plugins are only meant to be used inside a gradle build as a plugin rather than as a dependency. Maybe that's partly why the plugins are stored under prefix gradle.plugin. I think it should be kept this way. This is also why it makes sense to keep this dependency on plugins.gradle.org

from swagger-codegen-gradle-plugin.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.