-
Notifications
You must be signed in to change notification settings - Fork 207
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
Added gradle task to generate THIRD-PARTY License report #621
Added gradle task to generate THIRD-PARTY License report #621
Conversation
Codecov Report
@@ Coverage Diff @@
## main #621 +/- ##
=========================================
Coverage 91.58% 91.58%
Complexity 568 568
=========================================
Files 72 72
Lines 1747 1747
Branches 145 145
=========================================
Hits 1600 1600
Misses 113 113
Partials 34 34 Continue to review full report at Codecov.
|
build.gradle
Outdated
renderers = new TextReportRenderer() | ||
} | ||
|
||
task copyThirdParyReport(type: Copy) { |
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.
The plugin should be creating a large text file which has all the dependencies. That one file should be the one that should overwrite the THIRD-PARTY
file. This is copying all the .txt
files. It should probably copy one specific file to the THIRD-PARTY
file.
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.
Yeah, I was not sure whether to replace it or create a new one.
build.gradle
Outdated
renderers = new TextReportRenderer() | ||
} | ||
|
||
task copyThirdParyReport(type: Copy) { |
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 suggest a different name like generateThirdPartyReport
. This task also needs to depend on the task from the dependency-license-report
plugin. Otherwise, a developer will need to run two tasks.
include '*.txt' | ||
rename 'THIRD-PARTY-NOTICES.txt', 'THIRD-PARTY' | ||
rename 'THIRD-PARTY-NOTICES.txt', 'THIRD-PARTY' |
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.
Is this a duplicate renaming?
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.
My bad
build.gradle
Outdated
from 'build/reports/dependency-license/' | ||
into '.' | ||
include '*.txt' |
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 would be better to only copy the file that is needed. Otherwise, if the plugin changes to output multiple files they will end up in the root. This could end up being confusing.
Can this line just be?
include 'THIRD-PARTY-NOTICES.txt'
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.
Yes
Signed-off-by: Asif Sohail Mohammed <[email protected]>
648e392
to
31dcb2b
Compare
Signed-off-by: Asif Sohail Mohammed <[email protected]>
31dcb2b
to
088df66
Compare
…project#621) * Added gradle task to generate THIRD-PARTY License report Signed-off-by: Asif Sohail Mohammed <[email protected]> Co-authored-by: Asif Sohail Mohammed <[email protected]>
Signed-off-by: Asif Sohail Mohammed [email protected]
Description
Issues Resolved
Resolves #615
Check List
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.