-
Notifications
You must be signed in to change notification settings - Fork 7.6k
Standardize java source headers #7205
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
Standardize java source headers #7205
Conversation
Update Checkstyle to validate all java source files have a standard header. Remove FixLiscenseHeaders.java unit test as it duplicates Checkstyle functionality. Standard header is block java comment, instead of dangling Javadoc comment. Create standard header template (HEADER_JAVA) in project root. Reference header template in build.gradle. Update CONTRIBUTING.md to exact text of header template.
Standardize License based off of HEADER_JAVA file. All headers are block Java comments.
Please don't remove the FixLicenseHeaders. |
Also please do not change the license start date, it should be 2016. |
Codecov Report
@@ Coverage Diff @@
## 3.x #7205 +/- ##
============================================
- Coverage 99.54% 99.53% -0.01%
- Complexity 6757 6758 +1
============================================
Files 747 747
Lines 47387 47387
Branches 6384 6384
============================================
- Hits 47170 47167 -3
- Misses 99 101 +2
- Partials 118 119 +1
Continue to review full report at Codecov.
|
Will fix. Do you have an issue with the header validation in Checkstyle being an error as I have it, or should I change it to a warning? I saw in comments on other commits that errors might not be welcome from Checkstyle. |
Also should all the Licenses have a 2016 date? I saw a handful of them that had different dates (i.e. 2017). |
Several files had 2017 dates for License. Checkstyle now specifically looks for 2016 date in License comments.
Convert License headers to block comments instead of dangling Javadoc comments. Use Checkstyle to validate Java source files have Licenses attached. Updated Checkstyle to most recent version. Updated Checkstyle configuration to remove mostly commented out code and update to correct DTD.
Removed unit test FixLicenseHeaders as the functionality is handled by the Checkstyle header validation.
One commit is Checkstyle and Gradle updates. Second commit is for all the Java source License updates.
Fixes #7204