README.md 2.08 KB
Newer Older
Mark Malone's avatar
Mark Malone committed
1
# hello-world
Mark Malone's avatar
Mark Malone committed
2
 [![pipeline status](https://code.80px.com/80px/80px.com/java/hello-world/badges/main/pipeline.svg)](https://code.80px.com/80px/80px.com/java/hello-world/-/commits/main) [![coverage report](https://code.80px.com/80px/80px.com/java/hello-world/badges/main/coverage.svg)](https://code.80px.com/80px/80px.com/java/hello-world/-/commits/main) 
Mark Malone's avatar
Mark Malone committed
3

Mark Malone's avatar
Mark Malone committed
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
hello-world is a java project to return "Hello world".

## Installation

Download [java](https://www.oracle.com/java/technologies/javase-downloads.html) to run hello-world.


## Usage


### Building the program

```bash
./mvnw package
```
```bash

[INFO] --- maven-jar-plugin:2.4:jar (default-jar) @ hello-world ---
[INFO] Building jar: /home/markm/code/80px/template_projects/java/hello-world/target/hello-world-1.0-SNAPSHOT.jar
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  3.116 s
[INFO] Finished at: 2021-07-27T21:23:30-07:00
[INFO] ------------------------------------------------------------------------
```

### Running the program

```bash
java -cp target/hello-world-1.0-SNAPSHOT.jar com.eightzeropx.helloworld.Helloworld
```

```bash
Hello world!
```


### Testing the program

```bash
./mvnw test
```

```bash
...
[INFO] -------------------------------------------------------
[INFO]  T E S T S
[INFO] -------------------------------------------------------
[INFO] Running com.eightzeropx.helloworld.HelloworldTests
Hello world!
[INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.061 s - in com.eightzeropx.helloworld.HelloworldTests
[INFO] 
[INFO] Results:
[INFO] 
[INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0
[INFO] 
...
```

There is not command line coverage% reporting with `jacoco`. You can browse the web page it generates at `target/site/jacoco/index.html` to view the coverage report.

## Contributing
See [CONTRIBUTING.md](https://code.80px.com/80px/80px.com/java/hello-world/-/blob/main/CONTRIBUTING.md)

## License
[MIT](https://choosealicense.com/licenses/mit/)