You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@seatunnel.apache.org by GitBox <gi...@apache.org> on 2022/02/15 17:11:45 UTC
[GitHub] [incubator-seatunnel] ruanwenjun opened a new pull request #1250: [hotfix] [checkstyle] Fix Import order of java in checkstyle
ruanwenjun opened a new pull request #1250:
URL: https://github.com/apache/incubator-seatunnel/pull/1250
## Purpose of this pull request
When I import the checkstyle in IDEA, and find the import order of java.* is not in our expected.
for example:
```java
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import java.io.File;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import java.util.Objects;
import java.util.ServiceConfigurationError;
import java.util.ServiceLoader;
```
when I format it will look like below
```java
import java.io.File;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import java.util.Objects;
import java.util.ServiceConfigurationError;
import java.util.ServiceLoader;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
```
My checkstyle version is 9.2.
I find this was caused by the ImportOrder in checkstyle.xml.
Maybe this is the right config.
```
<property name="staticGroups" value="org.apache.seatunnel,org.apache.seatunnel.shade,*,javax,java.,scala"/>
<property name="groups" value="org.apache.seatunnel,org.apache.seatunnel.shade,*,javax,java.*,scala"/>
```
## Check list
* [ ] Code changed are covered with tests, or it does not need tests for reason:
* [ ] If any new Jar binary package adding in you PR, please add License Notice according
[New License Guide](https://github.com/apache/incubator-seatunnel/blob/dev/docs/en/developement/NewLicenseGuide.md)
* [ ] If necessary, please update the documentation to describe the new feature. https://github.com/apache/incubator-seatunnel/tree/dev/docs
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-seatunnel] CalvinKirs merged pull request #1250: [hotfix] [checkstyle] Fix Import order of java in checkstyle
Posted by GitBox <gi...@apache.org>.
CalvinKirs merged pull request #1250:
URL: https://github.com/apache/incubator-seatunnel/pull/1250
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@seatunnel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org