Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Refactor Maven Runner build config #2911
Refactor Maven Runner build config #2911
Changes from 1 commit
4c8cfcd
d3c4c7c
baefed3
bf195e8
c7617d6
f7db0d3
91f0314
835c6e5
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
This file was deleted.
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.
Instead of worrying about Sync/Copy tasks overwriting, and having to use
preserve {}
, I think it's best to always use Sync into the task's temporary dir, and use a final Sync task (prepareMavenPluginBuildDir
) to sync the files from the other Sync tasks in one go.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.
Unfortunately the generated
maven-plugin-help.properties
contains a timestamp, so Gradle will always consider the output out-of-date.I wrote this code to fix it - but maybe there's a Maven flag that will disable the timestamp?
This is perhaps a bit OTT/pre-optimising.
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 actually don't understand what helpMojo is supposed to achieve, and I can't google anything sensible. It looks like it should either generate the
help
goal (which Dokka's Maven plugin doesn't have) or maybe add some help documentation? Were you able to figure it out?Nothing looks broken to me, so I think it's fine to ignore the timestamp. Perhaps, at some point our Maven plugin should be revisited as well 😅
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 auto generates a 'help' command based on the properties in the Maven plugin
The file it generates is in
runners/maven-plugin/build/maven/generated-sources
But, like you, I'm not sure! I've never developed a Maven plugin.
I was looking at other options, and I found this Gradle plugin: https://github.com/britter/maven-plugin-development. It might help with developing a Maven plugin, but on the other hand, the current approach seems to be working.