Skip to content

Commit

Permalink
Adding information on README.md. Adding maven-assembly-plugin in the …
Browse files Browse the repository at this point in the history
…pom.xml.
  • Loading branch information
Mariana Azevedo committed May 11, 2020
1 parent 960e997 commit 8c8717b
Show file tree
Hide file tree
Showing 4 changed files with 42 additions and 4 deletions.
6 changes: 5 additions & 1 deletion .classpath
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,11 @@
<attribute name="test" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="src" path="src/main/resources"/>
<classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8">
<attributes>
<attribute name="maven.pomderived" value="true"/>
Expand Down
1 change: 1 addition & 0 deletions .settings/org.eclipse.core.resources.prefs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
eclipse.preferences.version=1
encoding//src/main/java=UTF-8
encoding//src/main/resources=UTF-8
encoding//src/test/java=UTF-8
encoding/<project>=UTF-8
20 changes: 19 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

A project of solved exercises from Hackerrank website in Java and SQL.

## Summary
### Summary

#### Java Challenges

Expand All @@ -14,3 +14,21 @@ A project of solved exercises from Hackerrank website in Java and SQL.
#### SQL Challenges

- [Practice SQL](https://github.com/mariazevedo88/hackerrank-challenges/blob/master/sql/SQL.md)

#### Run the .jar file

In order to run any Java Challenge in the project, on **Linux/Mac/Windows** terminal, run the jar simply as following:

```bash
java -cp hackerrank-challenges-1.0.0-SNAPSHOT-jar-with-dependencies.jar {Class that you want execute}
```

For example, to run the `Matrix.java` in the `Graphs` section:

```bash
java -cp hackerrank-challenges-1.0.0-SNAPSHOT-jar-with-dependencies.jar io.github.mariazevedo88.hc.prepkit.graphs.Matrix
```

#### Contributing

[![](https://sourcerer.io/fame/mariazevedo88/mariazevedo88/hackerrank-challenges/images/0)](https://sourcerer.io/fame/mariazevedo88/mariazevedo88/hackerrank-challenges/links/0)[![](https://sourcerer.io/fame/mariazevedo88/mariazevedo88/hackerrank-challenges/images/1)](https://sourcerer.io/fame/mariazevedo88/mariazevedo88/hackerrank-challenges/links/1)[![](https://sourcerer.io/fame/mariazevedo88/mariazevedo88/hackerrank-challenges/images/2)](https://sourcerer.io/fame/mariazevedo88/mariazevedo88/hackerrank-challenges/links/2)[![](https://sourcerer.io/fame/mariazevedo88/mariazevedo88/hackerrank-challenges/images/3)](https://sourcerer.io/fame/mariazevedo88/mariazevedo88/hackerrank-challenges/links/3)[![](https://sourcerer.io/fame/mariazevedo88/mariazevedo88/hackerrank-challenges/images/4)](https://sourcerer.io/fame/mariazevedo88/mariazevedo88/hackerrank-challenges/links/4)[![](https://sourcerer.io/fame/mariazevedo88/mariazevedo88/hackerrank-challenges/images/5)](https://sourcerer.io/fame/mariazevedo88/mariazevedo88/hackerrank-challenges/links/5)[![](https://sourcerer.io/fame/mariazevedo88/mariazevedo88/hackerrank-challenges/images/6)](https://sourcerer.io/fame/mariazevedo88/mariazevedo88/hackerrank-challenges/links/6)[![](https://sourcerer.io/fame/mariazevedo88/mariazevedo88/hackerrank-challenges/images/7)](https://sourcerer.io/fame/mariazevedo88/mariazevedo88/hackerrank-challenges/links/7)
19 changes: 17 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

<groupId>io.github.mariazevedo88</groupId>
<artifactId>hackerrank-challenges</artifactId>
<version>0.0.1-SNAPSHOT</version>
<version>1.0.0-SNAPSHOT</version>
<packaging>jar</packaging>

<name>hackerrank-challenges</name>
Expand Down Expand Up @@ -41,7 +41,6 @@
</dependencies>

<build>
<finalName>hackerrank-challenges</finalName>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
Expand All @@ -52,6 +51,22 @@
<target>${java.version}</target>
</configuration>
</plugin>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
</execution>
</executions>
<configuration>
<descriptorRefs>
<descriptorRef>jar-with-dependencies</descriptorRef>
</descriptorRefs>
</configuration>
</plugin>
</plugins>
</build>
</project>

0 comments on commit 8c8717b

Please sign in to comment.