Skip to content

Commit 7083962

Browse files
author
Bob Garner
committed
Improved maven project file and updated project README.md to explain how to build and run the compiler.
1 parent ee310c7 commit 7083962

File tree

2 files changed

+18
-13
lines changed

2 files changed

+18
-13
lines changed

README.md

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,20 @@ Although many working microservices have been built using this compiler and its
5353

5454
## Building and Running
5555

56-
The next release will include a Maven project file that will allow you to build. For now, the current Github release includes a `ec.jar` jar file. To run the compiler simply perform: `java -jar ec.jar` followed by arguments (for instance: `java -jar ec.jar -help`)
56+
> It is recommended to use version 3.6.0 or above of Maven (use `mvn --version` to get its version if it is already installed).
57+
58+
This repository includes a Maven project file (`pom.xml`). This allows you to build the project and create an "executable" jar file. To do this, open a shell and go inside the repository's local directory (aka Project Directory) and run:
59+
60+
mvn clean package
61+
62+
This will build the project and produce a directory called `target`. Inside this `target` directory there should be the built jar file `ec.jar`. You may want to move this jar file to a `bin` directory in your local account (such as `~/bin`), then also have a shell script in this `bin` directory that wraps this jar file to appear as a command line executable. For example, you could create a file called just `ec` (located in your `bin` directory) that looks like the following:
63+
64+
```shell
65+
#!/bin/sh
66+
java -jar ~/bin/ec.jar $@
67+
```
68+
69+
Then to run the compiler in a shell simply perform: `ec` followed by arguments (for instance: `ec -help`)
5770

5871
## Licensing
5972

pom.xml

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
<groupId>org.entityc</groupId>
1414
<artifactId>Entity-Compiler</artifactId>
15-
<version>1.0-SNAPSHOT</version>
15+
<version>0.12.1</version>
1616
<packaging>jar</packaging>
1717

1818
<properties>
@@ -31,16 +31,6 @@
3131
</plugins>
3232
</pluginManagement>
3333
<plugins>
34-
<plugin>
35-
<groupId>org.apache.maven.plugins</groupId>
36-
<artifactId>maven-jar-plugin</artifactId>
37-
<version>3.2.2</version>
38-
<configuration>
39-
<archive>
40-
<manifestFile>src/main/resources/META-INF/MANIFEST.MF</manifestFile>
41-
</archive>
42-
</configuration>
43-
</plugin>
4434
<plugin>
4535
<groupId>org.antlr</groupId>
4636
<artifactId>antlr4-maven-plugin</artifactId>
@@ -62,6 +52,7 @@
6252
</plugin>
6353
<plugin>
6454
<artifactId>maven-assembly-plugin</artifactId>
55+
<version>3.3.0</version>
6556
<executions>
6657
<execution>
6758
<phase>package</phase>
@@ -71,6 +62,7 @@
7162
</execution>
7263
</executions>
7364
<configuration>
65+
<finalName>ec</finalName>
7466
<appendAssemblyId>false</appendAssemblyId>
7567
<archive>
7668
<manifest>
@@ -131,4 +123,4 @@
131123
<version>4.9</version>
132124
</dependency>
133125
</dependencies>
134-
</project>
126+
</project>

0 commit comments

Comments
 (0)