-
Notifications
You must be signed in to change notification settings - Fork 2
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
Updating build to gradle 6.1 and adding publishing options. #61
base: master
Are you sure you want to change the base?
Conversation
* Updating gradle from 4.9 -> 6.1 * Updating from using java plugin -> java-library plugin * Adding publishing section to build to allow publishing to local and remote repositories
Tests are failing because travis no longer offers oraclejdk8 on the newer vms. I think we can fix this by pegging ourselves to an old version of ubuntu, but the best/easiest thing is probably to just switch to testing on openjdk8. The newest versions of oracle jdk 8 require a restrictive license and the old versions are only available with an oracle login, so it's pretty annoying. |
* Fixes failing travis tests by switching to openjdk8. OracleJdk 8 seems to be unavailable on the newer travis vms.
Codecov Report
@@ Coverage Diff @@
## master #61 +/- ##
=========================================
Coverage 84.36% 84.36%
Complexity 126 126
=========================================
Files 8 8
Lines 339 339
Branches 60 60
=========================================
Hits 286 286
Misses 42 42
Partials 11 11 Continue to review full report at Codecov.
|
@lbergelson, thanks for starting with the contribution/collaboration! First, could you please separate (in two PRs) the publishing from the gradle update? I have to think about publishing strategy/coordinates in maven and thus we can leave that for a different PR to discuss there. In addition, I'd like to keep the dirty marker when a build is done with changes in the local repository (should not happen on the CI build) to be sure that it's not coming from committed changes. The SNAPSHOT is a good addition, as I am planning to keep snapshots from master until a realease is done. |
* remove publishing and keep dirty status
@magicDGS I've removed the publishing bit and kept the "dirty" status. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some questions about the version variable. Once they are solved, we're ready to merge and close #56
build.gradle
Outdated
@@ -117,6 +124,7 @@ tasks.withType(Jar) { | |||
// add manifest information | |||
manifest { | |||
attributes 'Implementation-Title': rootProject.name, | |||
'Implementation-Version': version | |||
'Implementation-Version': archiveVersion |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Where this archiveVersion comes from? Should it also be changed above?
version gitVersion() | ||
|
||
final isRelease = Boolean.getBoolean("release") | ||
version = (isRelease ? gitVersion() : gitVersion() + "-SNAPSHOT") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If in the manifest we are changing the variable, is this still valid? Shouldn't it be archiveVersion?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it gets propagated but maybe it's too confusing. In the jar plugin they've deprecated the jar.version
and replaced it with jar.archiveVersion
property which is initialized with project.version
which is this. I think I'll use project.version in both places.
@magicDGS Updated |
@magicDGS I think I addressed your comments, let me know if you have more. |
I've added a publishing section that publishes to the same places that most broad projects are published. This is more a proof of concept than a working option since you might have different publishing targets. I've tested publishing to the broad artifactory with my credentials and that works, as does publishing to maven local. I haven't / can't publish to sonatype because I don't control the org.magicdgs namespace.
I edited the version a bit to drop the
.dirty
and addSNAPSHOT
when relevant. Happy to make whatever changes you prefer though. The snapshot bit is necessary I think for dealing with maven snapshot repositories but removing dirty is not important.I need to add publishing options so I can make it easy to test against gatk.