Skip to content

Commit

Permalink
[Java] fix license format conflict with checkstyle (#16)
Browse files Browse the repository at this point in the history
* test ci

* fix ci script

* remove fury-benchmark
  • Loading branch information
chaokunyang committed May 3, 2023
1 parent eb3dfb4 commit 5bb4c61
Show file tree
Hide file tree
Showing 10 changed files with 42 additions and 10 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/java-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ jobs:
java-version: ${{ matrix.java-version }}
distribution: 'temurin'
- name: Build with Maven
run: .ci/run_ci.sh java${{ matrix.java-version }}
run: ./ci/run_ci.sh java${{ matrix.java-version }}
2 changes: 1 addition & 1 deletion ci/run_ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ case $1 in
# check naming and others
mvn -T16 checkstyle:check
set +e
mvn -T16 test -pl '!fury-format,!fury-testsuite,!fury-benchmark'
mvn -T16 test -pl '!fury-format,!fury-testsuite'
testcode=$?
if [[ $testcode -ne 0 ]]; then
exit $testcode
Expand Down
2 changes: 1 addition & 1 deletion java/HEADER
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright 2023 FURY.
Copyright ${license.git.copyrightYears} The Fury authors
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
Expand Down
2 changes: 1 addition & 1 deletion java/fury-core/src/main/java/io/fury/Fury.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2023 FURY.
* Copyright 2023 The Fury authors
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
Expand Down
3 changes: 2 additions & 1 deletion java/fury-core/src/test/java/io/fury/FuryTest.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2023 FURY.
* Copyright 2023 The Fury authors
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
Expand All @@ -15,6 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/

package io.fury;

public class FuryTest {}
2 changes: 1 addition & 1 deletion java/fury-format/src/main/java/io/fury/format/row/Row.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2023 FURY.
* Copyright 2023 The Fury authors
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2023 FURY.
* Copyright 2023 The Fury authors
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
Expand All @@ -15,6 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/

package io.fury.format.row;

public class RowTest {}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2023 FURY.
* Copyright 2023 The Fury authors
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
Expand Down
13 changes: 13 additions & 0 deletions java/license-format.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?>
<additionalHeaders>
<SLASHSTART_WITH_BLANKLINE_STYLE>
<firstLine><![CDATA[/*]]></firstLine>
<beforeEachLine><![CDATA[ * ]]></beforeEachLine>
<endLine><![CDATA[ */EOL]]></endLine>
<firstLineDetectionPattern><![CDATA[(EOL)*(\s|\t)*/\*.*$]]></firstLineDetectionPattern>
<lastLineDetectionPattern><![CDATA[.*\*/(\s|\t)*$]]></lastLineDetectionPattern>
<allowBlankLines>false</allowBlankLines>
<isMultiline>true</isMultiline>
<padLines>false</padLines>
</SLASHSTART_WITH_BLANKLINE_STYLE>
</additionalHeaders>
21 changes: 19 additions & 2 deletions java/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
<arrow.version>5.0.0</arrow.version>
<jackson-bom.version>2.13.2.20220328</jackson-bom.version>
<commons_codec.version>1.13</commons_codec.version>
<license.maven.plugin>3.0</license.maven.plugin>
<license.maven.plugin>4.2</license.maven.plugin>
</properties>

<dependencyManagement>
Expand Down Expand Up @@ -233,17 +233,34 @@
</execution>
</executions>
<configuration>
<properties>
<project.inceptionYear>2023</project.inceptionYear>
</properties>
<quiet>true</quiet>
<header>HEADER</header>
<includes>
<include>**/src/main/java/**</include>
<include>**/src/test/java/**</include>
</includes>
<excludes>
<exclude>**/util/Platform.java</exclude>
</excludes>
<strictCheck>true</strictCheck>
<headerDefinitions>
<headerDefinition>license-format.xml</headerDefinition>
</headerDefinitions>
<mapping>
<java>SLASHSTAR_STYLE</java>
<java>SLASHSTART_WITH_BLANKLINE_STYLE</java>
</mapping>
</configuration>
<dependencies>
<dependency>
<groupId>com.mycila</groupId>
<artifactId>license-maven-plugin-git</artifactId>
<!-- make sure same version as license-maven-plugin -->
<version>${license.maven.plugin}</version>
</dependency>
</dependencies>
</plugin>
</plugins>
</build>
Expand Down

0 comments on commit 5bb4c61

Please sign in to comment.