Browse Source

Add SpringHeaderCheck to enforce using "2012-present"

This commit also fixes copyright headers that don't follow it.

See gh-46527

Signed-off-by: Johnny Lim <izeye@naver.com>
pull/46604/head
Johnny Lim 5 months ago committed by Stéphane Nicoll
parent
commit
62f379cbbb
  1. 2
      spring-boot-project/spring-boot-docs/src/main/java/org/springframework/boot/docs/web/graphql/runtimewiring/GreetingController.java
  2. 2
      spring-boot-project/spring-boot/src/main/java/org/springframework/boot/context/metrics/buffering/BufferedStartupStep.java
  3. 2
      spring-boot-project/spring-boot/src/main/java/org/springframework/boot/context/metrics/buffering/BufferingApplicationStartup.java
  4. 2
      spring-boot-project/spring-boot/src/main/java/org/springframework/boot/context/metrics/buffering/StartupTimeline.java
  5. 2
      spring-boot-project/spring-boot/src/main/java/org/springframework/boot/context/properties/ConstructorBound.java
  6. 2
      spring-boot-project/spring-boot/src/main/java/org/springframework/boot/convert/PeriodStyle.java
  7. 2
      spring-boot-project/spring-boot/src/main/java/org/springframework/boot/convert/PeriodToStringConverter.java
  8. 3
      src/checkstyle/checkstyle.xml

2
spring-boot-project/spring-boot-docs/src/main/java/org/springframework/boot/docs/web/graphql/runtimewiring/GreetingController.java

@ -1,5 +1,5 @@ @@ -1,5 +1,5 @@
/*
* Copyright 2002-present the original author or authors.
* Copyright 2012-present the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.

2
spring-boot-project/spring-boot/src/main/java/org/springframework/boot/context/metrics/buffering/BufferedStartupStep.java

@ -1,5 +1,5 @@ @@ -1,5 +1,5 @@
/*
* Copyright 2002-present the original author or authors.
* Copyright 2012-present the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.

2
spring-boot-project/spring-boot/src/main/java/org/springframework/boot/context/metrics/buffering/BufferingApplicationStartup.java

@ -1,5 +1,5 @@ @@ -1,5 +1,5 @@
/*
* Copyright 2002-present the original author or authors.
* Copyright 2012-present the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.

2
spring-boot-project/spring-boot/src/main/java/org/springframework/boot/context/metrics/buffering/StartupTimeline.java

@ -1,5 +1,5 @@ @@ -1,5 +1,5 @@
/*
* Copyright 2002-present the original author or authors.
* Copyright 2012-present the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.

2
spring-boot-project/spring-boot/src/main/java/org/springframework/boot/context/properties/ConstructorBound.java

@ -1,5 +1,5 @@ @@ -1,5 +1,5 @@
/*
* Copyright 2019-present the original author or authors.
* Copyright 2012-present the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.

2
spring-boot-project/spring-boot/src/main/java/org/springframework/boot/convert/PeriodStyle.java

@ -1,5 +1,5 @@ @@ -1,5 +1,5 @@
/*
* Copyright 2002-present the original author or authors.
* Copyright 2012-present the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.

2
spring-boot-project/spring-boot/src/main/java/org/springframework/boot/convert/PeriodToStringConverter.java

@ -1,5 +1,5 @@ @@ -1,5 +1,5 @@
/*
* Copyright 2002-present the original author or authors.
* Copyright 2012-present the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.

3
src/checkstyle/checkstyle.xml

@ -7,6 +7,9 @@ @@ -7,6 +7,9 @@
<property name="file" value="${config_loc}/checkstyle-suppressions.xml"/>
</module>
<module name="io.spring.javaformat.checkstyle.SpringChecks" />
<module name="io.spring.javaformat.checkstyle.check.SpringHeaderCheck">
<property name="headerCopyrightPattern" value="2012-present" />
</module>
<module name="com.puppycrawl.tools.checkstyle.TreeWalker">
<module name="io.spring.javaformat.checkstyle.check.SpringDeprecatedCheck" />
<module name="io.spring.javaformat.checkstyle.check.SpringJUnit5Check" />

Loading…
Cancel
Save