-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Makes shipkit / nexusPublish a convention plugin for root #3533
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
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3533 +/- ##
=========================================
Coverage 85.55% 85.55%
Complexity 2955 2955
=========================================
Files 341 341
Lines 8995 8995
Branches 1119 1119
=========================================
Hits 7696 7696
Misses 1009 1009
Partials 290 290 ☔ View full report in Codecov by Sentry. |
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 nits, the rest LGTM
buildSrc/src/main/kotlin/mockito.root.releasing-conventions.gradle.kts
Outdated
Show resolved
Hide resolved
gradle/libs.versions.toml
Outdated
@@ -11,6 +11,9 @@ gradleplugin-animal-sniffer = "1.7.2" | |||
gradleplugin-aQute-bnd = "7.0.0" | |||
gradleplugin-errorprone = "4.1.0" | |||
gradleplugin-spotless = "6.25.0" | |||
gradleplugin-nexusPublish = "2.0.0-rc-1" | |||
gradleplugin-shipkit-changelog = "2.0.1" | |||
gradleplugin-shipkit-autoVersion = "2.1.0" |
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.
Nit: since there is only 1 plugin that uses this version, I think it is duplicate to put it here as well. Therefore, if there is only one artifact with a particular version reference, I would prefer to use version
instead of version.ref
tasks { | ||
generateChangelog { | ||
githubToken = providers.environmentVariable("GITHUB_TOKEN").get() | ||
previousRevision = project.ext["shipkit-auto-version.previous-tag"].toString() |
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.
In a follow-up PR, let's refactor this so that we also use an environment variable for this.
dependsOn(generateChangelog) | ||
githubToken = providers.environmentVariable("GITHUB_TOKEN").get() | ||
newTagRevision = providers.environmentVariable("GITHUB_SHA").get() | ||
repository = generateChangelog.get().repository |
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.
WDYT about defining constants values instead of referencing separate tasks here. That removes the need for eager configuration
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.
Indeed that came to mind. I avoided this here to make a 1:1 translation. But this would be better in my opinion.
# Conflicts: # build.gradle.kts # gradle/libs.versions.toml
e50e5ae
to
e7d8627
Compare
e7d8627
to
22c4243
Compare
Sibling of #3532
Following on the trend to follow best practice, the
shipkit.gradle
script is now a convention plugin for the root project.One more step to help on #3474
Checklist
including project members to get a better picture of the change
commit is meaningful and help the people that will explore a change in 2 years
Fixes #<issue number>
in the description if relevantFixes #<issue number>
if relevant