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

gradle metadata support (gradle-4.6) #230

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

vvlevchenko
Copy link

No description provided.

@eyalbe4
Copy link
Contributor

eyalbe4 commented Jan 17, 2019

@vvlevchenko,
Thank you for this PR and sorry for the late reply.
The code looks okay, but we'd feel much more comfortable merging it if ti included a test for the new functionality.
The README includes instructions for running the tests.
As for adding new tests, you can see that the plugin code include these test projects. In each test project, the build.gradle references one of these build files, to create a full project to execute with gradle.
The GradleBintrayPluginSpec class includes the actual test methods, which test the above projects.

@vvlevchenko
Copy link
Author

I've reconsidered usefulness of this PR. It tries to cover difference between Gradle's maven publication representation and bintray plugin's maven publication representation. Months later after my initial changes I've concluded that it better to avoid duplication work done in Gradle's plugin maven-publish. My suggestion to fix this issue and all future possible mismatch in representation of maven publication for users preferring bintray plugin to maven-publish is to replace current maven publication upload functionality with applying maven-publish and its proper configuration (url and etc) under the hood of bintray plugin.

@LouisCAD
Copy link

@vvlevchenko Is there an example of using maven-publish to upload artifacts to bintray?

@ilmat192
Copy link

@LouisCAD You can take a look at maven-publish usage in this project: https://github.com/h0tk3y/better-parse/blob/fb2d5fb81b2a5eaccbe30419295f21ce1f70e5b0/build.gradle#L126.

This build script also contains some additional logic to avoid publishing the same artifacts from several hosts (you can find this logic before the publishing block). You may use the same approach or just allow bintray to override artifacts published several times. To do that, just append ;override=1 to the repo URL.

@LouisCAD
Copy link

@ilmat192 Thank you, that's very helpful!
About the name propery you set to "bintray" in the maven { … } closure, do I need to name it as such too? What does it translate to from the bintray config?

@ilmat192
Copy link

About the name propery you set to "bintray" in the maven { … } closure, do I need to name it as such too?

I don't think so. According to the Gradle docs this name is needed only to distinguish repositories from each other.

@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

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.

5 participants