Skip to content

Commit

Permalink
Merge pull request #1041 from bitwiseman/task/eol
Browse files Browse the repository at this point in the history
Only run spotless:check as part of the lifecyle
  • Loading branch information
bitwiseman authored Feb 26, 2021
2 parents a04ab45 + f08299b commit 40cfb85
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 10 deletions.
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
*.java text eol=lf
3 changes: 1 addition & 2 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@ We love getting PRs, but we hate asking people for the same basic changes every
- [ ] Push your changes to a branch other than `master`. Create your PR from that branch.
- [ ] Add JavaDocs and other comments
- [ ] Write tests that run and pass in CI. See [CONTRIBUTING.md](CONTRIBUTING.md) for details on how to capture snapshot data.
- [ ] Run `mvn clean compile` locally. This may reformat your code, commit those changes.
- [ ] Run `mvn -D enable-ci clean install site` locally. If this command doesn't succeed, your change will not pass CI.
- [ ] Run `mvn -D enable-ci clean install site` locally. If this command doesn't succeed, your change will not pass CI.

# When creating a PR:

Expand Down
26 changes: 18 additions & 8 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@
<hamcrest.version>2.2</hamcrest.version>
<okhttp3.version>4.4.1</okhttp3.version>
<okio.version>2.5.0</okio.version>
<spotless-maven-plugin.goal>apply</spotless-maven-plugin.goal>
<!-- Using this as the minimum bar for code coverage. Adding methods without covering them will fail this. -->
<jacoco.coverage.target.bundle.method>0.70</jacoco.coverage.target.bundle.method>
<jacoco.coverage.target.class.method>0.50</jacoco.coverage.target.class.method>
Expand Down Expand Up @@ -325,13 +324,14 @@
<plugin>
<groupId>com.diffplug.spotless</groupId>
<artifactId>spotless-maven-plugin</artifactId>
<version>2.7.0</version>
<version>2.8.1</version>
<executions>
<execution>
<id>spotless-check</id>
<phase>process-sources</phase>
<!-- runs in verify phase by default -->
<goals>
<goal>${spotless-maven-plugin.goal}</goal>
<!-- can be disabled using -Dspotless.check.skip=true -->
<goal>check</goal>
</goals>
</execution>
</executions>
Expand Down Expand Up @@ -574,7 +574,6 @@
<properties>
<!-- Only fail code coverage on non-windows machines -->
<jacoco.haltOnFailure>true</jacoco.haltOnFailure>
<spotless-maven-plugin.goal>check</spotless-maven-plugin.goal>
</properties>
</profile>
<profile>
Expand All @@ -590,14 +589,25 @@
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>com.diffplug.spotless</groupId>
<artifactId>spotless-maven-plugin</artifactId>
<executions>
<execution>
<id>spotless-check</id>
<!-- In CI, run check early in the build -->
<phase>process-sources</phase>
<goals>
<goal>check</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>release</id>
<properties>
<spotless-maven-plugin.goal>check</spotless-maven-plugin.goal>
</properties>
<build>
<plugins>
<plugin>
Expand Down

0 comments on commit 40cfb85

Please sign in to comment.