Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/gaol/java-parent

Maven parent project with handy configuration and plugins
https://github.com/gaol/java-parent

Last synced: 19 days ago
JSON representation

Maven parent project with handy configuration and plugins

Awesome Lists containing this project

README

        

# java-parent
Maven parent project with handy configuration and plugins

## Enable debug when executing the test case

> mvn clean install -Djpda

or

> mvn clean install -Pjpda

This will start the `maven-surefire-plugin` with the following arguments:

> -agentlib:jdwp=transport=dt_socket,address=8787,server=y,suspend=y

The test will suspend and wait remote debugging on part: `8787`

## Run tests on JDK 9 +

Modules are introduced in JDK9+, to be able to run the tests on JDK9+, the following arguments are added:

```
--add-exports=java.base/sun.nio.ch=ALL-UNNAMED
--add-exports=jdk.unsupported/sun.reflect=ALL-UNNAMED
--add-exports=jdk.unsupported/sun.misc=ALL-UNNAMED
--add-modules=java.se
```

## How to use this project

* Add parent to your pom:

```

io.github.gaol
java-parent
1.0.1

```

that is all.

### Release your project

If you specify this parent project, you can use the following command to do maven release and deploy to [Sonatype](https://oss.sonatype.org/):

```
mvn -Prelease release:prepare
mvn -Prelease release:perform
```

### Some notes to release to maven central

* Specify project name, description, url in your pom
* Specify SCM information in your pom
* Specify developer information in your pom

More requirement, refer to: https://central.sonatype.org/pages/requirements.html