GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Introduced a multi module java-diff-utils. The core project now has n… · GronwD/java-diff-utils@7d17c60

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • java-diff-utils-jgit
    • nb-configuration.xml
    • pom.xml
    • src
      • main/java/com/github/difflib/algorithm/jgit
        • HistogramDiff.java
      • test
        • java/com/github/difflib/algorithm/jgit
          • HistogramDiffTest.java
          • LRHistogramDiffTest.java
        • resources/mocks
          • large_dataset1.zip
  • java-diff-utils
    • pom.xml
    • src
      • main/java/com/github/difflib
        • DiffUtils.java
        • UnifiedDiffUtils.java
        • algorithm
          • Change.java
          • DiffAlgorithmI.java
          • DiffAlgorithmListener.java
          • DiffException.java
          • DifferentiationFailedException.java
          • myers
            • MyersDiff.java
            • PathNode.java
        • patch
          • AbstractDelta.java
          • ChangeDelta.java
          • Chunk.java
          • DeleteDelta.java
          • DeltaType.java
          • DiffException.java
          • InsertDelta.java
          • Patch.java
          • PatchFailedException.java
        • text
          • DiffRow.java
          • DiffRowGenerator.java
          • StringUtils.java
        • unifieddiff
          • UnifiedDiff.java
          • UnifiedDiffFile.java
          • UnifiedDiffParserException.java
          • UnifiedDiffReader.java
          • UnifiedDiffWriter.java
          • package-info.java
      • test
        • java/com/github/difflib
          • DiffUtilsTest.java
          • GenerateUnifiedDiffTest.java
          • TestConstants.java
          • algorithm/myers
            • MyersDiffTest.java
          • examples
            • ApplyPatch.java
            • ComputeDifference.java
          • patch
            • PatchTest.java
          • text
            • DiffRowGeneratorTest.java
            • StringUtilsTest.java
          • unifieddiff
            • UnifiedDiffReaderTest.java
            • UnifiedDiffRoundTripTest.java
            • UnifiedDiffWriterTest.java
        • resources
          • com/github/difflib/unifieddiff
            • jsqlparser_patch_1.diff
            • problem_diff_issue33.diff
            • problem_diff_issue46.diff
          • mocks
            • 5A.txt
            • 5B.txt
            • issue10_base.txt
            • issue10_patch.txt
            • issue11_1.txt
            • issue11_2.txt
            • issue15_1.txt
            • issue15_2.txt
            • one_delta_test_original.txt
            • one_delta_test_revised.txt
            • original.txt
            • revised.txt
  • pom.xml

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Dismiss banner
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎java-diff-utils-jgit/nb-configuration.xml‎

Copy file name to clipboard
+19Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<project-shared-configuration>
3+
<!--
4+
This file contains additional configuration written by modules in the NetBeans IDE.
5+
The configuration is intended to be shared among all the users of project and
6+
therefore it is assumed to be part of version control checkout.
7+
Without this configuration present, some functionality in the IDE may be limited or fail altogether.
8+
-->
9+
<properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
10+
<!--
11+
Properties that influence various parts of the IDE, especially code formatting and the like.
12+
You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
13+
That way multiple projects can share the same settings (useful for formatting rules for example).
14+
Any value defined here will override the pom.xml file value but is only applicable to the current project.
15+
-->
16+
<netbeans.compile.on.save>none</netbeans.compile.on.save>
17+
<netbeans.hint.jdkPlatform>JDK_1.8</netbeans.hint.jdkPlatform>
18+
</properties>
19+
</project-shared-configuration>
Collapse file

‎java-diff-utils-jgit/pom.xml‎

Copy file name to clipboard
+58Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
3+
<modelVersion>4.0.0</modelVersion>
4+
<parent>
5+
<groupId>io.github.java-diff-utils</groupId>
6+
<artifactId>java-diff-utils-parent</artifactId>
7+
<version>4.1-SNAPSHOT</version>
8+
</parent>
9+
<artifactId>java-diff-utils-jgit</artifactId>
10+
<packaging>jar</packaging>
11+
<description>This is an extension of java-diff-utils using jgit to use its implementation of
12+
some difference algorithms.</description>
13+
<dependencies>
14+
<dependency>
15+
<groupId>junit</groupId>
16+
<artifactId>junit</artifactId>
17+
<version>4.12</version>
18+
<type>jar</type>
19+
<scope>test</scope>
20+
</dependency>
21+
<dependency>
22+
<groupId>org.eclipse.jgit</groupId>
23+
<artifactId>org.eclipse.jgit</artifactId>
24+
<version>4.4.1.201607150455-r</version>
25+
<exclusions>
26+
<exclusion>
27+
<groupId>com.googlecode.javaewah</groupId>
28+
<artifactId>JavaEWAH</artifactId>
29+
</exclusion>
30+
<exclusion>
31+
<groupId>commons-codec</groupId>
32+
<artifactId>commons-codec</artifactId>
33+
</exclusion>
34+
<exclusion>
35+
<groupId>commons-logging</groupId>
36+
<artifactId>commons-logging</artifactId>
37+
</exclusion>
38+
<exclusion>
39+
<groupId>org.apache.httpcomponents</groupId>
40+
<artifactId>httpclient</artifactId>
41+
</exclusion>
42+
<exclusion>
43+
<groupId>com.jcraft</groupId>
44+
<artifactId>jsch</artifactId>
45+
</exclusion>
46+
<exclusion>
47+
<groupId>org.slf4j</groupId>
48+
<artifactId>slf4j-api</artifactId>
49+
</exclusion>
50+
</exclusions>
51+
</dependency>
52+
<dependency>
53+
<groupId>${project.groupId}</groupId>
54+
<artifactId>java-diff-utils</artifactId>
55+
<version>${project.version}</version>
56+
</dependency>
57+
</dependencies>
58+
</project>
Collapse file

‎…ifflib/algorithm/jgit/HistogramDiff.java‎ ‎…ifflib/algorithm/jgit/HistogramDiff.java‎src/main/java/com/github/difflib/algorithm/jgit/HistogramDiff.java renamed to java-diff-utils-jgit/src/main/java/com/github/difflib/algorithm/jgit/HistogramDiff.java src/main/java/com/github/difflib/algorithm/jgit/HistogramDiff.java renamed to java-diff-utils-jgit/src/main/java/com/github/difflib/algorithm/jgit/HistogramDiff.java

Copy file name to clipboard
File renamed without changes.
Collapse file

‎…ib/algorithm/jgit/HistogramDiffTest.java‎ ‎…ib/algorithm/jgit/HistogramDiffTest.java‎src/test/java/com/github/difflib/algorithm/jgit/HistogramDiffTest.java renamed to java-diff-utils-jgit/src/test/java/com/github/difflib/algorithm/jgit/HistogramDiffTest.java src/test/java/com/github/difflib/algorithm/jgit/HistogramDiffTest.java renamed to java-diff-utils-jgit/src/test/java/com/github/difflib/algorithm/jgit/HistogramDiffTest.java

Copy file name to clipboard
File renamed without changes.
Collapse file

‎…/algorithm/jgit/LRHistogramDiffTest.java‎ ‎…/algorithm/jgit/LRHistogramDiffTest.java‎src/test/java/com/github/difflib/algorithm/jgit/LRHistogramDiffTest.java renamed to java-diff-utils-jgit/src/test/java/com/github/difflib/algorithm/jgit/LRHistogramDiffTest.java src/test/java/com/github/difflib/algorithm/jgit/LRHistogramDiffTest.java renamed to java-diff-utils-jgit/src/test/java/com/github/difflib/algorithm/jgit/LRHistogramDiffTest.java

Copy file name to clipboardExpand all lines: java-diff-utils-jgit/src/test/java/com/github/difflib/algorithm/jgit/LRHistogramDiffTest.java
+14-3Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,18 @@
1515
*/
1616
package com.github.difflib.algorithm.jgit;
1717

18-
import static com.github.difflib.DiffUtilsTest.readStringListFromInputStream;
19-
import com.github.difflib.TestConstants;
2018
import com.github.difflib.algorithm.DiffAlgorithmListener;
2119
import com.github.difflib.patch.Patch;
2220
import com.github.difflib.patch.PatchFailedException;
21+
import java.io.BufferedReader;
2322
import java.io.IOException;
23+
import java.io.InputStream;
24+
import java.io.InputStreamReader;
25+
import java.nio.charset.Charset;
26+
import java.nio.charset.StandardCharsets;
2427
import java.util.ArrayList;
2528
import java.util.List;
29+
import static java.util.stream.Collectors.toList;
2630
import java.util.zip.ZipFile;
2731
import org.junit.After;
2832
import org.junit.AfterClass;
@@ -58,7 +62,7 @@ public void tearDown() {
5862

5963
@Test
6064
public void testPossibleDiffHangOnLargeDatasetDnaumenkoIssue26() throws IOException, PatchFailedException {
61-
ZipFile zip = new ZipFile(TestConstants.MOCK_FOLDER + "/large_dataset1.zip");
65+
ZipFile zip = new ZipFile("target/test-classes/mocks/large_dataset1.zip");
6266
List<String> original = readStringListFromInputStream(zip.getInputStream(zip.getEntry("ta")));
6367
List<String> revised = readStringListFromInputStream(zip.getInputStream(zip.getEntry("tb")));
6468

@@ -88,4 +92,11 @@ public void diffEnd() {
8892
assertEquals(246579, logdata.size());
8993
}
9094

95+
public static List<String> readStringListFromInputStream(InputStream is) throws IOException {
96+
try (BufferedReader reader = new BufferedReader(
97+
new InputStreamReader(is, Charset.forName(StandardCharsets.UTF_8.name())))) {
98+
99+
return reader.lines().collect(toList());
100+
}
101+
}
91102
}
Collapse file

‎…/test/resources/mocks/large_dataset1.zip‎ ‎…/test/resources/mocks/large_dataset1.zip‎src/test/resources/mocks/large_dataset1.zip renamed to java-diff-utils-jgit/src/test/resources/mocks/large_dataset1.zip src/test/resources/mocks/large_dataset1.zip renamed to java-diff-utils-jgit/src/test/resources/mocks/large_dataset1.zip

Copy file name to clipboard
File renamed without changes.
Collapse file

‎java-diff-utils/pom.xml‎

Copy file name to clipboard
+60Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
2+
<modelVersion>4.0.0</modelVersion>
3+
<groupId>io.github.java-diff-utils</groupId>
4+
<artifactId>java-diff-utils</artifactId>
5+
<packaging>jar</packaging>
6+
<name>java-diff-utils</name>
7+
<parent>
8+
<groupId>io.github.java-diff-utils</groupId>
9+
<artifactId>java-diff-utils-parent</artifactId>
10+
<version>4.1-SNAPSHOT</version>
11+
</parent>
12+
<properties>
13+
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
14+
</properties>
15+
16+
<dependencies>
17+
<dependency>
18+
<groupId>junit</groupId>
19+
<artifactId>junit</artifactId>
20+
<version>4.12</version>
21+
<type>jar</type>
22+
<scope>test</scope>
23+
</dependency>
24+
<dependency>
25+
<groupId>org.assertj</groupId>
26+
<artifactId>assertj-core</artifactId>
27+
<version>3.11.1</version>
28+
<scope>test</scope>
29+
</dependency>
30+
</dependencies>
31+
32+
<build>
33+
<plugins>
34+
<plugin>
35+
<groupId>org.apache.maven.plugins</groupId>
36+
<artifactId>maven-compiler-plugin</artifactId>
37+
<version>3.6.1</version>
38+
<configuration>
39+
<source>1.8</source>
40+
<target>1.8</target>
41+
<encoding>UTF-8</encoding>
42+
</configuration>
43+
</plugin>
44+
<plugin>
45+
<artifactId>maven-jar-plugin</artifactId>
46+
<version>3.0.2</version>
47+
<configuration>
48+
<archive>
49+
<manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
50+
<manifestEntries>
51+
<!-- identical to OSGI name -->
52+
<Automatic-Module-Name>io.github.java-diff-utils</Automatic-Module-Name>
53+
</manifestEntries>
54+
</archive>
55+
</configuration>
56+
</plugin>
57+
</plugins>
58+
</build>
59+
</project>
60+
Collapse file

‎…n/java/com/github/difflib/DiffUtils.java‎ ‎…n/java/com/github/difflib/DiffUtils.java‎src/main/java/com/github/difflib/DiffUtils.java renamed to java-diff-utils/src/main/java/com/github/difflib/DiffUtils.java src/main/java/com/github/difflib/DiffUtils.java renamed to java-diff-utils/src/main/java/com/github/difflib/DiffUtils.java

Copy file name to clipboard
File renamed without changes.
Collapse file

‎…com/github/difflib/UnifiedDiffUtils.java‎ ‎…com/github/difflib/UnifiedDiffUtils.java‎src/main/java/com/github/difflib/UnifiedDiffUtils.java renamed to java-diff-utils/src/main/java/com/github/difflib/UnifiedDiffUtils.java src/main/java/com/github/difflib/UnifiedDiffUtils.java renamed to java-diff-utils/src/main/java/com/github/difflib/UnifiedDiffUtils.java

Copy file name to clipboard
File renamed without changes.
Collapse file

‎…com/github/difflib/algorithm/Change.java‎ ‎…com/github/difflib/algorithm/Change.java‎src/main/java/com/github/difflib/algorithm/Change.java renamed to java-diff-utils/src/main/java/com/github/difflib/algorithm/Change.java src/main/java/com/github/difflib/algorithm/Change.java renamed to java-diff-utils/src/main/java/com/github/difflib/algorithm/Change.java

Copy file name to clipboard
File renamed without changes.

0 commit comments

Comments
0 (0)
You are visitor 01402520 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.