Does this plugin work with Gradle Plugin DSL?
See original GitHub issueI’m trying to enable it like this in my root build.gradle file:
plugins {
id "de.mannodermaus.android-junit5" version "1.4.2.0"
}
In my settings.gradle I have the following:
pluginManagement {
repositories {
google()
mavenCentral()
gradlePluginPortal()
}
}
However whenever I try to sync I receive the following error:
Plugin [id: ‘de.mannodermaus.android-junit5’, version: ‘1.4.2.0’] was not found in any of the following sources:
- Gradle Core Plugins (plugin is not in ‘org.gradle’ namespace)
- Plugin Repositories (could not resolve plugin artifact ‘de.mannodermaus.android-junit5:de.mannodermaus.android-junit5.gradle.plugin:1.4.2.0’) Searched in the following repositories: Google MavenRepo Gradle Central Plugin Repository
So, can I use it together with new Plugins DSL?
Issue Analytics
- State:
- Created 4 years ago
- Comments:6 (2 by maintainers)
Top Results From Across the Web
Using Gradle Plugins
The plugins DSL provides a succinct and convenient way to declare plugin dependencies. It works with the Gradle plugin portal to provide easy...
Read more >What the difference in applying gradle plugin - Stack Overflow
plugins works in multi-project, according to Gradle tutorial (Gradle version 5.6.2) guides.gradle.org/creating-multi-project-builds/… It uses ...
Read more >Chapter 21. Gradle Plugins
The new plugins DSL provides a more succinct and convenient way to declare plugin dependencies. It works with the new Gradle plugin portal...
Read more >Introduction to writing Gradle plugins - Tom Gregory
1) Expose one or more tasks to allow you to run some specific action · 2) Perform some behaviour automatically when the plugin...
Read more >5. Add Gradle Plugin with Dependencies - Spring Cloud
Plugin DSL GA versions. // build.gradle plugins { id "groovy" // this will work only for GA versions of Spring Cloud Contract id...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This plugin doesn’t expose the necessary plugin marker artifact required by the Plugins DSL. You’d need a custom resolution strategy to map to the correct coordinates in your
pluginManagement
block:The Android Gradle Plugin also doesn’t support the Plugins DSL, as far as I’m aware. Do you resolve that plugin similarly?
I quickly verified @autonomousapps’ statement and this actually works as well, although you need to strip away the version off the line inside the
plugins
block.@Lingviston, as an alternative to the workaround mentioned above, this works as well:
Either of these approaches should work fine for your use case.