Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ignore failOnDynamicVersions() to fetch latest versions #593

Merged
merged 2 commits into from
Mar 26, 2022

Conversation

keykey7
Copy link
Contributor

@keykey7 keykey7 commented Mar 25, 2022

Provides a way to fetch the latest version despite having resolutionStrategy.failOnDynamicVersions() active.
Gradle does not expose an official way to disable this check once activated currently. The proposed solution relies on the implementation of the internal DefaultResolutionStrategy, but is generally backwards compatible.

resolves #592

Comment on lines 44 to 46
import org.gradle.api.internal.artifacts.configurations.DefaultConfiguration
import org.gradle.api.internal.artifacts.configurations.ResolutionStrategyInternal
import org.gradle.api.internal.artifacts.ivyservice.resolutionstrategy.DefaultResolutionStrategy
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks like you don't need these anymore?

@ben-manes ben-manes merged commit 028df6f into ben-manes:master Mar 26, 2022
@ben-manes
Copy link
Owner

Thanks! great idea and approach :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

failOnDynamicVersions() prevents fetching latest version
2 participants