Skip to content

Commit 402f789

Browse files
committed
1 parent 7f10375 commit 402f789

File tree

3 files changed

+23
-112
lines changed

3 files changed

+23
-112
lines changed

README.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,10 @@ The XmlDiff utility compares two XML files and generates a third file that repre
1818
To run the difference utility, run this command line:
1919

2020
```
21-
java io.fixprotocol.xml.XmlDiff <in-file1> <in-file2> [output-file]
21+
java -jar diff-merge-1.5.1-SNAPSHOT-jar-with-dependencies.jar <arguments>
22+
23+
Usage: XmlDiff <xml-file1> <xml-file2> [diff-file] [-e event-file] [-u|-o]
24+
diff-file defaults to console -u=unordered elements -o=ordered elements
2225
```
2326
If the output file is not provided, then results go to the console.
2427

pom.xml

Lines changed: 18 additions & 110 deletions
Original file line numberDiff line numberDiff line change
@@ -112,127 +112,35 @@
112112
</configuration>
113113
</plugin>
114114
<plugin>
115-
<artifactId>maven-resources-plugin</artifactId>
116-
<version>3.1.0</version>
117-
<executions>
118-
<execution>
119-
<id>copy-resources</id>
120-
<phase>verify</phase>
121-
<goals>
122-
<goal>copy-resources</goal>
123-
</goals>
124-
<configuration>
125-
<outputDirectory>${project.build.directory}/modules</outputDirectory>
126-
<resources>
127-
<resource>
128-
<directory>${project.build.directory}</directory>
129-
<includes>
130-
<include>*.jar</include>
131-
</includes>
132-
</resource>
133-
</resources>
134-
</configuration>
135-
</execution>
136-
</executions>
137-
</plugin>
138-
<plugin>
139-
<groupId>org.apache.maven.plugins</groupId>
140-
<artifactId>maven-dependency-plugin</artifactId>
141-
<version>3.1.1</version>
115+
<artifactId>maven-assembly-plugin</artifactId>
116+
<version>3.3.0</version>
117+
<configuration>
118+
<descriptorRefs>
119+
<descriptorRef>jar-with-dependencies</descriptorRef>
120+
</descriptorRefs>
121+
<archive>
122+
<manifest>
123+
<mainClass>io.fixprotocol.xml.XmlDiff</mainClass>
124+
</manifest>
125+
<manifestEntries>
126+
<Multi-Release>true</Multi-Release>
127+
</manifestEntries>
128+
</archive>
129+
</configuration>
142130
<executions>
143131
<execution>
144-
<id>copy-dependencies</id>
145-
<phase>verify</phase>
132+
<id>make-assembly</id>
133+
<phase>package</phase>
146134
<goals>
147-
<goal>copy-dependencies</goal>
135+
<goal>single</goal>
148136
</goals>
149-
<configuration>
150-
<outputDirectory>${project.build.directory}/modules</outputDirectory>
151-
<overWriteIfNewer>true</overWriteIfNewer>
152-
<includeGroupIds>org.apache.logging.log4j</includeGroupIds>
153-
</configuration>
154137
</execution>
155138
</executions>
156139
</plugin>
157140
</plugins>
158141
</build>
159142

160143
<profiles>
161-
<profile>
162-
<id>image</id>
163-
<build>
164-
<plugins>
165-
<!-- Create an image using jlink -->
166-
<!-- Works with fork donmendelson/moditect to support multiple entry points -->
167-
<plugin>
168-
<groupId>org.moditect</groupId>
169-
<artifactId>moditect-maven-plugin</artifactId>
170-
<version>1.0.0-SNAPSHOT</version>
171-
<executions>
172-
<execution>
173-
<id>add-module-infos</id>
174-
<phase>generate-resources</phase>
175-
<goals>
176-
<goal>add-module-info</goal>
177-
</goals>
178-
<configuration>
179-
<outputDirectory>${project.build.directory}/modules</outputDirectory>
180-
<overwriteExistingFiles>true</overwriteExistingFiles>
181-
<ignoreSigningInformation>true</ignoreSigningInformation>
182-
<modules>
183-
<module>
184-
<artifact>
185-
<groupId>net.sf.saxon</groupId>
186-
<artifactId>Saxon-HE</artifactId>
187-
<version>${saxon.version}</version>
188-
</artifact>
189-
<moduleInfoSource>
190-
module Saxon.HE {
191-
192-
}
193-
</moduleInfoSource>
194-
</module>
195-
</modules>
196-
</configuration>
197-
</execution>
198-
<execution>
199-
<!-- due to an apparent plugin bug, must run after clean -->
200-
<!-- for unknown reason, this step does not work in Eclipse -->
201-
<id>create-runtime-image</id>
202-
<phase>install</phase>
203-
<goals>
204-
<goal>create-runtime-image</goal>
205-
</goals>
206-
<configuration>
207-
<modulePath>
208-
<path>${project.build.directory}/modules</path>
209-
</modulePath>
210-
<modules>
211-
<module>diff.merge</module>
212-
<module>Saxon.HE</module>
213-
</modules>
214-
<outputDirectory>
215-
${project.build.directory}/jlink-image
216-
</outputDirectory>
217-
<launchers>
218-
<launcher>
219-
<name>xmldiff</name>
220-
<module>diff.merge</module>
221-
<mainClass>io.fixprotocol.xml.XmlDiff</mainClass>
222-
</launcher>
223-
<launcher>
224-
<name>xmlmerge</name>
225-
<module>diff.merge</module>
226-
<mainClass>io.fixprotocol.xml.XmlMerge</mainClass>
227-
</launcher>
228-
</launchers>
229-
</configuration>
230-
</execution>
231-
</executions>
232-
</plugin>
233-
</plugins>
234-
</build>
235-
</profile>
236144
<profile>
237145
<id>release</id>
238146
<build>

src/main/java/io/fixprotocol/xml/XmlMerge.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ public class XmlMerge {
6565
* Merges a baseline XML file with a differences file to produce a second XML file
6666
*
6767
* @param args three file names: baseline XML file, diff file, name of second XML to produce
68-
* Optionally, argument '-e <event-filename>' can direct errors to a JSON file for UI rendering.
68+
* Optionally, argument '-e <event-filename>' can direct errors to a JSON file suitable for UI rendering.
6969
*
7070
*/
7171
public static void main(String[] args) {

0 commit comments

Comments
 (0)