The project contains a customized Maven archetype (Java8, Junit5) which I use as template for new Java projects for HackerRank.com challenges.
- Some info about Maven Archetypes could be found here: https://maven.apache.org/guides/introduction/introduction-to-archetypes.html
- Helpful was also the following Tutorial: https://www.baeldung.com/maven-archetype
To install the archetype in your local maven repository execute the following commands:
git clone https://github.com/ellevaoche/Elles-HackerRank-Quickstart-Archetpye.git
cd hackerrank-quickstart-archetype
mvn clean install
To generate a project from the custom archetype use one of the following methods:
mvn archetype:generate \
-DarchetypeGroupId=com.hackerrank \
-DarchetypeArtifactId=elle-hackerrank-quickstart-archetype \
-DarchetypeVersion=1.0.0-SNAPSHOT \
mvn archetype:generate \
-DinteractiveMode=false \
-DarchetypeGroupId=com.hackerrank \
-DarchetypeArtifactId=elle-hackerrank-quickstart-archetype \
-DarchetypeVersion=1.0.0-SNAPSHOT \
-DgroupId=[myCustom.groupid] \
-DartifactId=[myCustomArtifactId] \
-Dversion=[myCustomVersion]