diff options
148 files changed, 2512 insertions, 1791 deletions
@@ -17,3 +17,4 @@ Shawn Pearce <spearce@spearce.org> Shawn O. Pearce <sop Shawn Pearce <spearce@spearce.org> Shawn Pearce <sop@google.com> Shawn Pearce <spearce@spearce.org> Shawn O. Pearce <spearce@spearce.org> Terry Parker <tparker@google.com> tparker <tparker@google.com> +Thomas Wolf <twolf@apache.org> Thomas Wolf <thomas.wolf@paranor.ch> diff --git a/Documentation/config-options.md b/Documentation/config-options.md index cbcb36a250..3495813e76 100644 --- a/Documentation/config-options.md +++ b/Documentation/config-options.md @@ -50,6 +50,12 @@ For details on native git options see also the official [git config documentatio | `core.trustPackedRefsStat` | `unset` | ⃞ | Whether to trust the file attributes (Java equivalent of stat command on *nix) of the packed-refs file. If `never` JGit will ignore the file attributes of the packed-refs file and always read it. If `always` JGit will trust the file attributes of the packed-refs file and will only read it if a file attribute has changed. `after_open` behaves the same as `always`, except that the packed-refs file is opened and closed before its file attributes are considered. An open/close of the packed-refs file is known to refresh its file attributes, at least on some NFS clients. If `unset`, JGit will use the behavior described in `trustFolderStat`. | | `core.worktree` | Root directory of the working tree if it is not the parent directory of the `.git` directory | ✅ | The path to the root of the working tree. | +## __fetch__ options + +| option | default | git option | description | +|---------|---------|------------|-------------| +| `fetch.useNegotiationTip` | `false` | ✅ | When enabled it restricts the client negotiation on unrelated branches i.e. only send haves for the refs that the client is interested in fetching. | + ## __gc__ options | option | default | git option | description | @@ -269,9 +269,9 @@ BOUNCYCASTLE_VER = "1.72" maven_jar( name = "bcpg", - artifact = "org.bouncycastle:bcpg-jdk18on:" + BOUNCYCASTLE_VER, - sha1 = "1a36a1740d07869161f6f0d01fae8d72dd1d8320", - src_sha1 = "fe19ed35a28b345d00459de55cd20ad9e1385a4f", + artifact = "org.bouncycastle:bcpg-jdk18on:1.72.2", + sha1 = "ef29db0e82cf1ee99ddf5d772e810c1beb2d70f1", + src_sha1 = "72936958f07df15946f4eb6cd2ae558d8d24ed1c", ) maven_jar( diff --git a/org.eclipse.jgit.ant.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.ant.test/META-INF/MANIFEST.MF index 3ed4d95c30..8fb0714465 100644 --- a/org.eclipse.jgit.ant.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.ant.test/META-INF/MANIFEST.MF @@ -5,13 +5,13 @@ Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.ant.test Bundle-SymbolicName: org.eclipse.jgit.ant.test Bundle-Vendor: %Bundle-Vendor -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-ActivationPolicy: lazy Bundle-RequiredExecutionEnvironment: JavaSE-11 Import-Package: org.apache.tools.ant, - org.eclipse.jgit.ant.tasks;version="[6.5.1,6.6.0)", - org.eclipse.jgit.junit;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)", + org.eclipse.jgit.ant.tasks;version="[6.6.0,6.7.0)", + org.eclipse.jgit.junit;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)", org.hamcrest.core;version="[1.1.0,3.0.0)", org.junit;version="[4.13,5.0.0)" diff --git a/org.eclipse.jgit.ant.test/pom.xml b/org.eclipse.jgit.ant.test/pom.xml index 61e1b57fbe..e2f839eabe 100644 --- a/org.eclipse.jgit.ant.test/pom.xml +++ b/org.eclipse.jgit.ant.test/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.ant.test</artifactId> diff --git a/org.eclipse.jgit.ant/META-INF/MANIFEST.MF b/org.eclipse.jgit.ant/META-INF/MANIFEST.MF index 1cb6aca1ba..687750a4a4 100644 --- a/org.eclipse.jgit.ant/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.ant/META-INF/MANIFEST.MF @@ -3,13 +3,13 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.ant Bundle-SymbolicName: org.eclipse.jgit.ant -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-RequiredExecutionEnvironment: JavaSE-11 Import-Package: org.apache.tools.ant, - org.eclipse.jgit.storage.file;version="[6.5.1,6.6.0)" + org.eclipse.jgit.storage.file;version="[6.6.0,6.7.0)" Bundle-Localization: plugin Bundle-Vendor: %Bundle-Vendor -Export-Package: org.eclipse.jgit.ant;version="6.5.1", - org.eclipse.jgit.ant.tasks;version="6.5.1"; +Export-Package: org.eclipse.jgit.ant;version="6.6.0", + org.eclipse.jgit.ant.tasks;version="6.6.0"; uses:="org.apache.tools.ant, org.apache.tools.ant.types" diff --git a/org.eclipse.jgit.ant/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.ant/META-INF/SOURCE-MANIFEST.MF index 9dc6f642ce..758d9f8a49 100644 --- a/org.eclipse.jgit.ant/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.ant/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.ant - Sources Bundle-SymbolicName: org.eclipse.jgit.ant.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.5.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.ant;version="6.5.1.qualifier";roots="." +Bundle-Version: 6.6.0.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.ant;version="6.6.0.qualifier";roots="." diff --git a/org.eclipse.jgit.ant/pom.xml b/org.eclipse.jgit.ant/pom.xml index df42c00a65..ee2b15abbf 100644 --- a/org.eclipse.jgit.ant/pom.xml +++ b/org.eclipse.jgit.ant/pom.xml @@ -15,7 +15,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.ant</artifactId> diff --git a/org.eclipse.jgit.archive/META-INF/MANIFEST.MF b/org.eclipse.jgit.archive/META-INF/MANIFEST.MF index 446b1d5c70..0f980d126f 100644 --- a/org.eclipse.jgit.archive/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.archive/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.archive Bundle-SymbolicName: org.eclipse.jgit.archive -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-11 @@ -13,17 +13,17 @@ Import-Package: org.apache.commons.compress.archivers;version="[1.4,2.0)", org.apache.commons.compress.compressors.bzip2;version="[1.4,2.0)", org.apache.commons.compress.compressors.gzip;version="[1.4,2.0)", org.apache.commons.compress.compressors.xz;version="[1.4,2.0)", - org.eclipse.jgit.api;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.nls;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revwalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)", + org.eclipse.jgit.api;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.nls;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revwalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)", org.osgi.framework;version="[1.3.0,2.0.0)" Bundle-ActivationPolicy: lazy Bundle-Activator: org.eclipse.jgit.archive.FormatActivator -Export-Package: org.eclipse.jgit.archive;version="6.5.1"; +Export-Package: org.eclipse.jgit.archive;version="6.6.0"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.api, org.apache.commons.compress.archivers, org.osgi.framework", - org.eclipse.jgit.archive.internal;version="6.5.1";x-internal:=true + org.eclipse.jgit.archive.internal;version="6.6.0";x-internal:=true diff --git a/org.eclipse.jgit.archive/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.archive/META-INF/SOURCE-MANIFEST.MF index 2a1ba49f0c..ccdfb83325 100644 --- a/org.eclipse.jgit.archive/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.archive/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.archive - Sources Bundle-SymbolicName: org.eclipse.jgit.archive.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.5.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.archive;version="6.5.1.qualifier";roots="." +Bundle-Version: 6.6.0.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.archive;version="6.6.0.qualifier";roots="." diff --git a/org.eclipse.jgit.archive/pom.xml b/org.eclipse.jgit.archive/pom.xml index 615b932817..89c6cd602f 100644 --- a/org.eclipse.jgit.archive/pom.xml +++ b/org.eclipse.jgit.archive/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.archive</artifactId> diff --git a/org.eclipse.jgit.benchmarks/pom.xml b/org.eclipse.jgit.benchmarks/pom.xml index ae9c6a3236..02cfe56d82 100644 --- a/org.eclipse.jgit.benchmarks/pom.xml +++ b/org.eclipse.jgit.benchmarks/pom.xml @@ -14,7 +14,7 @@ <modelVersion>4.0.0</modelVersion> <groupId>org.eclipse.jgit</groupId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> <artifactId>org.eclipse.jgit.benchmarks</artifactId> <packaging>jar</packaging> diff --git a/org.eclipse.jgit.coverage/pom.xml b/org.eclipse.jgit.coverage/pom.xml index 34d2d7f2c6..191fe10123 100644 --- a/org.eclipse.jgit.coverage/pom.xml +++ b/org.eclipse.jgit.coverage/pom.xml @@ -14,7 +14,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <modelVersion>4.0.0</modelVersion> @@ -27,88 +27,88 @@ <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.ant</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.archive</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.http.apache</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.http.server</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.lfs</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.lfs.server</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.pgm</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.ui</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.ssh.apache</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.test</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.ant.test</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.http.test</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.pgm.test</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.lfs.test</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.lfs.server.test</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.ssh.apache.test</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> </dependencies> diff --git a/org.eclipse.jgit.gpg.bc.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.gpg.bc.test/META-INF/MANIFEST.MF index 175eaba8a9..5a1ead8d48 100644 --- a/org.eclipse.jgit.gpg.bc.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.gpg.bc.test/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.gpg.bc.test Bundle-SymbolicName: org.eclipse.jgit.gpg.bc.test -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-11 @@ -12,9 +12,9 @@ Import-Package: org.bouncycastle.jce.provider;version="[1.65.0,2.0.0)", org.bouncycastle.openpgp.operator;version="[1.65.0,2.0.0)", org.bouncycastle.openpgp.operator.jcajce;version="[1.65.0,2.0.0)", org.bouncycastle.util.encoders;version="[1.65.0,2.0.0)", - org.eclipse.jgit.gpg.bc.internal;version="[6.5.1,6.6.0)", - org.eclipse.jgit.gpg.bc.internal.keys;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util.sha1;version="[6.5.1,6.6.0)", + org.eclipse.jgit.gpg.bc.internal;version="[6.6.0,6.7.0)", + org.eclipse.jgit.gpg.bc.internal.keys;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util.sha1;version="[6.6.0,6.7.0)", org.hamcrest;version="[1.1.0,3.0.0)", org.junit;version="[4.13,5.0.0)", org.junit.runner;version="[4.13,5.0.0)", diff --git a/org.eclipse.jgit.gpg.bc.test/pom.xml b/org.eclipse.jgit.gpg.bc.test/pom.xml index 92175924c5..3d8ee59f79 100644 --- a/org.eclipse.jgit.gpg.bc.test/pom.xml +++ b/org.eclipse.jgit.gpg.bc.test/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.gpg.bc.test</artifactId> diff --git a/org.eclipse.jgit.gpg.bc/META-INF/MANIFEST.MF b/org.eclipse.jgit.gpg.bc/META-INF/MANIFEST.MF index 23ff36d46e..4284405eb1 100644 --- a/org.eclipse.jgit.gpg.bc/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.gpg.bc/META-INF/MANIFEST.MF @@ -3,10 +3,10 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.gpg.bc Bundle-SymbolicName: org.eclipse.jgit.gpg.bc;singleton:=true -Fragment-Host: org.eclipse.jgit;bundle-version="[6.5.1,6.6.0)" +Fragment-Host: org.eclipse.jgit;bundle-version="[6.6.0,6.7.0)" Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-RequiredExecutionEnvironment: JavaSE-11 Import-Package: org.bouncycastle.asn1;version="[1.69.0,2.0.0)", org.bouncycastle.asn1.cryptlib;version="[1.69.0,2.0.0)", @@ -29,9 +29,9 @@ Import-Package: org.bouncycastle.asn1;version="[1.69.0,2.0.0)", org.bouncycastle.util;version="[1.69.0,2.0.0)", org.bouncycastle.util.encoders;version="[1.69.0,2.0.0)", org.bouncycastle.util.io;version="[1.69.0,2.0.0)", - org.eclipse.jgit.annotations;version="[6.5.1,6.6.0)", - org.eclipse.jgit.api.errors;version="[6.5.1,6.6.0)", + org.eclipse.jgit.annotations;version="[6.6.0,6.7.0)", + org.eclipse.jgit.api.errors;version="[6.6.0,6.7.0)", org.slf4j;version="[1.7.0,2.0.0)" -Export-Package: org.eclipse.jgit.gpg.bc;version="6.5.1", - org.eclipse.jgit.gpg.bc.internal;version="6.5.1";x-friends:="org.eclipse.jgit.gpg.bc.test", - org.eclipse.jgit.gpg.bc.internal.keys;version="6.5.1";x-friends:="org.eclipse.jgit.gpg.bc.test" +Export-Package: org.eclipse.jgit.gpg.bc;version="6.6.0", + org.eclipse.jgit.gpg.bc.internal;version="6.6.0";x-friends:="org.eclipse.jgit.gpg.bc.test", + org.eclipse.jgit.gpg.bc.internal.keys;version="6.6.0";x-friends:="org.eclipse.jgit.gpg.bc.test" diff --git a/org.eclipse.jgit.gpg.bc/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.gpg.bc/META-INF/SOURCE-MANIFEST.MF index 6604381353..832bb03f79 100644 --- a/org.eclipse.jgit.gpg.bc/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.gpg.bc/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.gpg.bc - Sources Bundle-SymbolicName: org.eclipse.jgit.gpg.bc.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.5.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.gpg.bc;version="6.5.1.qualifier";roots="." +Bundle-Version: 6.6.0.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.gpg.bc;version="6.6.0.qualifier";roots="." diff --git a/org.eclipse.jgit.gpg.bc/pom.xml b/org.eclipse.jgit.gpg.bc/pom.xml index 59484ac982..01639face2 100644 --- a/org.eclipse.jgit.gpg.bc/pom.xml +++ b/org.eclipse.jgit.gpg.bc/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.gpg.bc</artifactId> diff --git a/org.eclipse.jgit.http.apache/META-INF/MANIFEST.MF b/org.eclipse.jgit.http.apache/META-INF/MANIFEST.MF index 0d798b68b3..16c3cc9c6d 100644 --- a/org.eclipse.jgit.http.apache/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.http.apache/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.http.apache Bundle-SymbolicName: org.eclipse.jgit.http.apache -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-RequiredExecutionEnvironment: JavaSE-11 Bundle-Localization: plugin Bundle-Vendor: %Bundle-Vendor @@ -25,11 +25,11 @@ Import-Package: org.apache.http;version="[4.3.0,5.0.0)", org.apache.http.impl.conn;version="[4.4.0,5.0.0)", org.apache.http.params;version="[4.3.0,5.0.0)", org.apache.http.ssl;version="[4.3.0,5.0.0)", - org.eclipse.jgit.annotations;version="[6.5.1,6.6.0)", - org.eclipse.jgit.nls;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.http;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)" -Export-Package: org.eclipse.jgit.transport.http.apache;version="6.5.1"; + org.eclipse.jgit.annotations;version="[6.6.0,6.7.0)", + org.eclipse.jgit.nls;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.http;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)" +Export-Package: org.eclipse.jgit.transport.http.apache;version="6.6.0"; uses:="org.apache.http.client, org.eclipse.jgit.transport.http, org.apache.http.entity, diff --git a/org.eclipse.jgit.http.apache/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.http.apache/META-INF/SOURCE-MANIFEST.MF index 4556a0eb78..ffda58ba4d 100644 --- a/org.eclipse.jgit.http.apache/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.http.apache/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.http.apache - Sources Bundle-SymbolicName: org.eclipse.jgit.http.apache.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.5.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.http.apache;version="6.5.1.qualifier";roots="." +Bundle-Version: 6.6.0.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.http.apache;version="6.6.0.qualifier";roots="." diff --git a/org.eclipse.jgit.http.apache/pom.xml b/org.eclipse.jgit.http.apache/pom.xml index d9a3370756..87c67ce85c 100644 --- a/org.eclipse.jgit.http.apache/pom.xml +++ b/org.eclipse.jgit.http.apache/pom.xml @@ -15,7 +15,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.http.apache</artifactId> diff --git a/org.eclipse.jgit.http.server/META-INF/MANIFEST.MF b/org.eclipse.jgit.http.server/META-INF/MANIFEST.MF index 4fd2f50196..845cdd3a44 100644 --- a/org.eclipse.jgit.http.server/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.http.server/META-INF/MANIFEST.MF @@ -3,13 +3,13 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.http.server Bundle-SymbolicName: org.eclipse.jgit.http.server -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Localization: plugin Bundle-Vendor: %Bundle-Vendor -Export-Package: org.eclipse.jgit.http.server;version="6.5.1", - org.eclipse.jgit.http.server.glue;version="6.5.1"; +Export-Package: org.eclipse.jgit.http.server;version="6.6.0", + org.eclipse.jgit.http.server.glue;version="6.6.0"; uses:="javax.servlet,javax.servlet.http", - org.eclipse.jgit.http.server.resolver;version="6.5.1"; + org.eclipse.jgit.http.server.resolver;version="6.6.0"; uses:="org.eclipse.jgit.transport.resolver, org.eclipse.jgit.lib, org.eclipse.jgit.transport, @@ -18,14 +18,14 @@ Bundle-ActivationPolicy: lazy Bundle-RequiredExecutionEnvironment: JavaSE-11 Import-Package: javax.servlet;version="[2.5.0,5.0.0)", javax.servlet.http;version="[2.5.0,5.0.0)", - org.eclipse.jgit.annotations;version="[6.5.1,6.6.0)", - org.eclipse.jgit.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.dfs;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.file;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.transport.parser;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.nls;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revwalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.resolver;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)" + org.eclipse.jgit.annotations;version="[6.6.0,6.7.0)", + org.eclipse.jgit.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.dfs;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.file;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.transport.parser;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.nls;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revwalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.resolver;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)" diff --git a/org.eclipse.jgit.http.server/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.http.server/META-INF/SOURCE-MANIFEST.MF index f51e928ff5..62eeeb616f 100644 --- a/org.eclipse.jgit.http.server/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.http.server/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.http.server - Sources Bundle-SymbolicName: org.eclipse.jgit.http.server.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.5.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.http.server;version="6.5.1.qualifier";roots="." +Bundle-Version: 6.6.0.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.http.server;version="6.6.0.qualifier";roots="." diff --git a/org.eclipse.jgit.http.server/pom.xml b/org.eclipse.jgit.http.server/pom.xml index ee395aee4d..67c99c63c5 100644 --- a/org.eclipse.jgit.http.server/pom.xml +++ b/org.eclipse.jgit.http.server/pom.xml @@ -19,7 +19,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.http.server</artifactId> diff --git a/org.eclipse.jgit.http.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.http.test/META-INF/MANIFEST.MF index e8beaab2e1..a6171eebcb 100644 --- a/org.eclipse.jgit.http.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.http.test/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.http.test Bundle-SymbolicName: org.eclipse.jgit.http.test -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-11 @@ -26,26 +26,26 @@ Import-Package: javax.servlet;version="[2.5.0,5.0.0)", org.eclipse.jetty.util.log;version="[10.0.0,11.0.0)", org.eclipse.jetty.util.security;version="[10.0.0,11.0.0)", org.eclipse.jetty.util.thread;version="[10.0.0,11.0.0)", - org.eclipse.jgit.api;version="[6.5.1,6.6.0)", - org.eclipse.jgit.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.http.server;version="[6.5.1,6.6.0)", - org.eclipse.jgit.http.server.glue;version="[6.5.1,6.6.0)", - org.eclipse.jgit.http.server.resolver;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.dfs;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.file;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.reftable;version="[6.5.1,6.6.0)", - org.eclipse.jgit.junit;version="[6.5.1,6.6.0)", - org.eclipse.jgit.junit.http;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.nls;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revwalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.storage.file;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.http;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.http.apache;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.resolver;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)", + org.eclipse.jgit.api;version="[6.6.0,6.7.0)", + org.eclipse.jgit.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.http.server;version="[6.6.0,6.7.0)", + org.eclipse.jgit.http.server.glue;version="[6.6.0,6.7.0)", + org.eclipse.jgit.http.server.resolver;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.dfs;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.file;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.reftable;version="[6.6.0,6.7.0)", + org.eclipse.jgit.junit;version="[6.6.0,6.7.0)", + org.eclipse.jgit.junit.http;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.nls;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revwalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.storage.file;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.http;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.http.apache;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.resolver;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)", org.hamcrest;version="[1.1.0,3.0.0)", org.hamcrest.core;version="[1.1.0,3.0.0)", org.junit;version="[4.13,5.0.0)", diff --git a/org.eclipse.jgit.http.test/pom.xml b/org.eclipse.jgit.http.test/pom.xml index 70ddc71060..3da269bf56 100644 --- a/org.eclipse.jgit.http.test/pom.xml +++ b/org.eclipse.jgit.http.test/pom.xml @@ -18,7 +18,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.http.test</artifactId> diff --git a/org.eclipse.jgit.junit.http/META-INF/MANIFEST.MF b/org.eclipse.jgit.junit.http/META-INF/MANIFEST.MF index 19aa7675b3..3ffb79ee7e 100644 --- a/org.eclipse.jgit.junit.http/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.junit.http/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.junit.http Bundle-SymbolicName: org.eclipse.jgit.junit.http -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Localization: plugin Bundle-Vendor: %Bundle-Vendor Bundle-ActivationPolicy: lazy @@ -21,17 +21,17 @@ Import-Package: javax.servlet;version="[2.5.0,5.0.0)", org.eclipse.jetty.util.log;version="[10.0.0,11.0.0)", org.eclipse.jetty.util.security;version="[10.0.0,11.0.0)", org.eclipse.jetty.util.ssl;version="[10.0.0,11.0.0)", - org.eclipse.jgit.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.http.server;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.file;version="[6.5.1,6.6.0)", - org.eclipse.jgit.junit;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revwalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.resolver;version="[6.5.1,6.6.0)", + org.eclipse.jgit.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.http.server;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.file;version="[6.6.0,6.7.0)", + org.eclipse.jgit.junit;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revwalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.resolver;version="[6.6.0,6.7.0)", org.junit;version="[4.13,5.0.0)", org.slf4j.helpers;version="[1.7.0,2.0.0)" -Export-Package: org.eclipse.jgit.junit.http;version="6.5.1"; +Export-Package: org.eclipse.jgit.junit.http;version="6.6.0"; uses:="org.eclipse.jgit.transport, org.eclipse.jgit.junit, javax.servlet.http, diff --git a/org.eclipse.jgit.junit.http/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.junit.http/META-INF/SOURCE-MANIFEST.MF index 13755c7f91..a004023529 100644 --- a/org.eclipse.jgit.junit.http/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.junit.http/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.junit.http - Sources Bundle-SymbolicName: org.eclipse.jgit.junit.http.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.5.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.junit.http;version="6.5.1.qualifier";roots="." +Bundle-Version: 6.6.0.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.junit.http;version="6.6.0.qualifier";roots="." diff --git a/org.eclipse.jgit.junit.http/pom.xml b/org.eclipse.jgit.junit.http/pom.xml index b1699d5273..ece2440b1d 100644 --- a/org.eclipse.jgit.junit.http/pom.xml +++ b/org.eclipse.jgit.junit.http/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.junit.http</artifactId> diff --git a/org.eclipse.jgit.junit.ssh/META-INF/MANIFEST.MF b/org.eclipse.jgit.junit.ssh/META-INF/MANIFEST.MF index 15df0bb650..3cf43481fe 100644 --- a/org.eclipse.jgit.junit.ssh/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.junit.ssh/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.junit.ssh Bundle-SymbolicName: org.eclipse.jgit.junit.ssh -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Localization: plugin Bundle-Vendor: %Bundle-Vendor Bundle-ActivationPolicy: lazy @@ -33,16 +33,16 @@ Import-Package: org.apache.sshd.common;version="[2.9.2,2.10.0)", org.apache.sshd.server.subsystem;version="[2.9.2,2.10.0)", org.apache.sshd.sftp;version="[2.9.2,2.10.0)", org.apache.sshd.sftp.server;version="[2.9.2,2.10.0)", - org.eclipse.jgit.annotations;version="[6.5.1,6.6.0)", - org.eclipse.jgit.api;version="[6.5.1,6.6.0)", - org.eclipse.jgit.api.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.junit;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revwalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)", + org.eclipse.jgit.annotations;version="[6.6.0,6.7.0)", + org.eclipse.jgit.api;version="[6.6.0,6.7.0)", + org.eclipse.jgit.api.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.junit;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revwalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)", org.junit;version="[4.13,5.0.0)", org.junit.experimental.theories;version="[4.13,5.0.0)", org.slf4j;version="[1.7.0,2.0.0)" -Export-Package: org.eclipse.jgit.junit.ssh;version="6.5.1" +Export-Package: org.eclipse.jgit.junit.ssh;version="6.6.0" diff --git a/org.eclipse.jgit.junit.ssh/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.junit.ssh/META-INF/SOURCE-MANIFEST.MF index a0b8e72ea5..9d50f9feb7 100644 --- a/org.eclipse.jgit.junit.ssh/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.junit.ssh/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.junit.ssh - Sources Bundle-SymbolicName: org.eclipse.jgit.junit.ssh.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.5.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.junit.ssh;version="6.5.1.qualifier";roots="." +Bundle-Version: 6.6.0.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.junit.ssh;version="6.6.0.qualifier";roots="." diff --git a/org.eclipse.jgit.junit.ssh/pom.xml b/org.eclipse.jgit.junit.ssh/pom.xml index 50e6e8460c..d0fb8bc96c 100644 --- a/org.eclipse.jgit.junit.ssh/pom.xml +++ b/org.eclipse.jgit.junit.ssh/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.junit.ssh</artifactId> diff --git a/org.eclipse.jgit.junit/META-INF/MANIFEST.MF b/org.eclipse.jgit.junit/META-INF/MANIFEST.MF index 479035cd23..870fe859ae 100644 --- a/org.eclipse.jgit.junit/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.junit/META-INF/MANIFEST.MF @@ -3,35 +3,35 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.junit Bundle-SymbolicName: org.eclipse.jgit.junit -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Localization: plugin Bundle-Vendor: %Bundle-Vendor Bundle-ActivationPolicy: lazy Bundle-RequiredExecutionEnvironment: JavaSE-11 -Import-Package: org.eclipse.jgit.annotations;version="[6.5.1,6.6.0)", - org.eclipse.jgit.api;version="[6.5.1,6.6.0)", - org.eclipse.jgit.api.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.dircache;version="[6.5.1,6.6.0)", - org.eclipse.jgit.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.file;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.pack;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.merge;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revwalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.storage.file;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport;version="6.5.1", - org.eclipse.jgit.treewalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.treewalk.filter;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util.io;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util.time;version="[6.5.1,6.6.0)", +Import-Package: org.eclipse.jgit.annotations;version="[6.6.0,6.7.0)", + org.eclipse.jgit.api;version="[6.6.0,6.7.0)", + org.eclipse.jgit.api.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.dircache;version="[6.6.0,6.7.0)", + org.eclipse.jgit.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.file;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.pack;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.merge;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revwalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.storage.file;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport;version="6.6.0", + org.eclipse.jgit.treewalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.treewalk.filter;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util.io;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util.time;version="[6.6.0,6.7.0)", org.junit;version="[4.13,5.0.0)", org.junit.rules;version="[4.13,5.0.0)", org.junit.runner;version="[4.13,5.0.0)", org.junit.runners;version="[4.13,5.0.0)", org.junit.runners.model;version="[4.13,5.0.0)", org.slf4j;version="[1.7.0,2.0.0)" -Export-Package: org.eclipse.jgit.junit;version="6.5.1"; +Export-Package: org.eclipse.jgit.junit;version="6.6.0"; uses:="org.eclipse.jgit.dircache, org.eclipse.jgit.lib, org.eclipse.jgit.revwalk, @@ -44,4 +44,4 @@ Export-Package: org.eclipse.jgit.junit;version="6.5.1"; org.junit.runners.model, org.junit.runner, org.eclipse.jgit.util.time", - org.eclipse.jgit.junit.time;version="6.5.1";uses:="org.eclipse.jgit.util.time" + org.eclipse.jgit.junit.time;version="6.6.0";uses:="org.eclipse.jgit.util.time" diff --git a/org.eclipse.jgit.junit/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.junit/META-INF/SOURCE-MANIFEST.MF index 388479a45e..ad44ed47bf 100644 --- a/org.eclipse.jgit.junit/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.junit/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.junit - Sources Bundle-SymbolicName: org.eclipse.jgit.junit.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.5.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.junit;version="6.5.1.qualifier";roots="." +Bundle-Version: 6.6.0.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.junit;version="6.6.0.qualifier";roots="." diff --git a/org.eclipse.jgit.junit/pom.xml b/org.eclipse.jgit.junit/pom.xml index a320406070..05eded2671 100644 --- a/org.eclipse.jgit.junit/pom.xml +++ b/org.eclipse.jgit.junit/pom.xml @@ -19,7 +19,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.junit</artifactId> diff --git a/org.eclipse.jgit.lfs.server.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.lfs.server.test/META-INF/MANIFEST.MF index af52de0ad8..dcc3dbc6a5 100644 --- a/org.eclipse.jgit.lfs.server.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.lfs.server.test/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.lfs.server.test Bundle-SymbolicName: org.eclipse.jgit.lfs.server.test -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-11 @@ -26,24 +26,24 @@ Import-Package: javax.servlet;version="[3.1.0,5.0.0)", org.eclipse.jetty.util.log;version="[10.0.0,11.0.0)", org.eclipse.jetty.util.security;version="[10.0.0,11.0.0)", org.eclipse.jetty.util.thread;version="[10.0.0,11.0.0)", - org.eclipse.jgit.api;version="[6.5.1,6.6.0)", - org.eclipse.jgit.api.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.file;version="[6.5.1,6.6.0)", - org.eclipse.jgit.junit;version="[6.5.1,6.6.0)", - org.eclipse.jgit.junit.http;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs.server;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs.server.fs;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs.test;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revwalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.storage.file;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport;version="[6.5.1,6.6.0)", - org.eclipse.jgit.treewalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.treewalk.filter;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)", + org.eclipse.jgit.api;version="[6.6.0,6.7.0)", + org.eclipse.jgit.api.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.file;version="[6.6.0,6.7.0)", + org.eclipse.jgit.junit;version="[6.6.0,6.7.0)", + org.eclipse.jgit.junit.http;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs.server;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs.server.fs;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs.test;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revwalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.storage.file;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport;version="[6.6.0,6.7.0)", + org.eclipse.jgit.treewalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.treewalk.filter;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)", org.hamcrest.core;version="[1.1.0,3.0.0)", org.junit;version="[4.13,5.0.0)", org.junit.rules;version="[4.13,5.0.0)", diff --git a/org.eclipse.jgit.lfs.server.test/pom.xml b/org.eclipse.jgit.lfs.server.test/pom.xml index 747f06a2bc..f23b42093c 100644 --- a/org.eclipse.jgit.lfs.server.test/pom.xml +++ b/org.eclipse.jgit.lfs.server.test/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.lfs.server.test</artifactId> diff --git a/org.eclipse.jgit.lfs.server/META-INF/MANIFEST.MF b/org.eclipse.jgit.lfs.server/META-INF/MANIFEST.MF index 20b9d106ca..f6bbed2285 100644 --- a/org.eclipse.jgit.lfs.server/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.lfs.server/META-INF/MANIFEST.MF @@ -3,19 +3,19 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.lfs.server Bundle-SymbolicName: org.eclipse.jgit.lfs.server -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Localization: plugin Bundle-Vendor: %Bundle-Vendor -Export-Package: org.eclipse.jgit.lfs.server;version="6.5.1"; +Export-Package: org.eclipse.jgit.lfs.server;version="6.6.0"; uses:="javax.servlet.http, org.eclipse.jgit.lfs.lib", - org.eclipse.jgit.lfs.server.fs;version="6.5.1"; + org.eclipse.jgit.lfs.server.fs;version="6.6.0"; uses:="javax.servlet, javax.servlet.http, org.eclipse.jgit.lfs.server, org.eclipse.jgit.lfs.lib", - org.eclipse.jgit.lfs.server.internal;version="6.5.1";x-internal:=true, - org.eclipse.jgit.lfs.server.s3;version="6.5.1"; + org.eclipse.jgit.lfs.server.internal;version="6.6.0";x-internal:=true, + org.eclipse.jgit.lfs.server.s3;version="6.6.0"; uses:="org.eclipse.jgit.lfs.server, org.eclipse.jgit.lfs.lib" Bundle-RequiredExecutionEnvironment: JavaSE-11 @@ -24,15 +24,15 @@ Import-Package: com.google.gson;version="[2.8.0,3.0.0)", javax.servlet.annotation;version="[3.1.0,5.0.0)", javax.servlet.http;version="[3.1.0,5.0.0)", org.apache.http;version="[4.3.0,5.0.0)", - org.eclipse.jgit.annotations;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.file;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs.internal;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.nls;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.http;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.http.apache;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)", + org.eclipse.jgit.annotations;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.file;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs.internal;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.nls;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.http;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.http.apache;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)", org.slf4j;version="[1.7.0,2.0.0)" diff --git a/org.eclipse.jgit.lfs.server/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.lfs.server/META-INF/SOURCE-MANIFEST.MF index 93eeea5a8b..006c685733 100644 --- a/org.eclipse.jgit.lfs.server/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.lfs.server/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.lfs.server - Sources Bundle-SymbolicName: org.eclipse.jgit.lfs.server.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.5.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.lfs.server;version="6.5.1.qualifier";roots="." +Bundle-Version: 6.6.0.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.lfs.server;version="6.6.0.qualifier";roots="." diff --git a/org.eclipse.jgit.lfs.server/pom.xml b/org.eclipse.jgit.lfs.server/pom.xml index 6b99508c9e..19acdb7a98 100644 --- a/org.eclipse.jgit.lfs.server/pom.xml +++ b/org.eclipse.jgit.lfs.server/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.lfs.server</artifactId> diff --git a/org.eclipse.jgit.lfs.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.lfs.test/META-INF/MANIFEST.MF index c1cdf3bfbd..c3327699e7 100644 --- a/org.eclipse.jgit.lfs.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.lfs.test/META-INF/MANIFEST.MF @@ -3,27 +3,27 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.lfs.test Bundle-SymbolicName: org.eclipse.jgit.lfs.test -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-11 -Import-Package: org.eclipse.jgit.api;version="[6.5.1,6.6.0)", - org.eclipse.jgit.attributes;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.dfs;version="[6.5.1,6.6.0)", - org.eclipse.jgit.junit;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs.internal;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revwalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.http;version="[6.5.1,6.6.0)", - org.eclipse.jgit.treewalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.treewalk.filter;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)", +Import-Package: org.eclipse.jgit.api;version="[6.6.0,6.7.0)", + org.eclipse.jgit.attributes;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.dfs;version="[6.6.0,6.7.0)", + org.eclipse.jgit.junit;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs.internal;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revwalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.http;version="[6.6.0,6.7.0)", + org.eclipse.jgit.treewalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.treewalk.filter;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)", org.hamcrest.core;version="[1.1.0,3.0.0)", org.junit;version="[4.13,5.0.0)", org.junit.runner;version="[4.13,5.0.0)", org.junit.runners;version="[4.13,5.0.0)" -Export-Package: org.eclipse.jgit.lfs.test;version="6.5.1";x-friends:="org.eclipse.jgit.lfs.server.test" +Export-Package: org.eclipse.jgit.lfs.test;version="6.6.0";x-friends:="org.eclipse.jgit.lfs.server.test" diff --git a/org.eclipse.jgit.lfs.test/pom.xml b/org.eclipse.jgit.lfs.test/pom.xml index a30bd541f9..65c4170c51 100644 --- a/org.eclipse.jgit.lfs.test/pom.xml +++ b/org.eclipse.jgit.lfs.test/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.lfs.test</artifactId> diff --git a/org.eclipse.jgit.lfs/META-INF/MANIFEST.MF b/org.eclipse.jgit.lfs/META-INF/MANIFEST.MF index fb8993b384..0f3e36f573 100644 --- a/org.eclipse.jgit.lfs/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.lfs/META-INF/MANIFEST.MF @@ -3,32 +3,32 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.lfs Bundle-SymbolicName: org.eclipse.jgit.lfs -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Localization: plugin Bundle-Vendor: %Bundle-Vendor -Export-Package: org.eclipse.jgit.lfs;version="6.5.1", - org.eclipse.jgit.lfs.errors;version="6.5.1", - org.eclipse.jgit.lfs.internal;version="6.5.1";x-friends:="org.eclipse.jgit.lfs.test,org.eclipse.jgit.lfs.server.fs,org.eclipse.jgit.lfs.server", - org.eclipse.jgit.lfs.lib;version="6.5.1" +Export-Package: org.eclipse.jgit.lfs;version="6.6.0", + org.eclipse.jgit.lfs.errors;version="6.6.0", + org.eclipse.jgit.lfs.internal;version="6.6.0";x-friends:="org.eclipse.jgit.lfs.test,org.eclipse.jgit.lfs.server.fs,org.eclipse.jgit.lfs.server", + org.eclipse.jgit.lfs.lib;version="6.6.0" Bundle-RequiredExecutionEnvironment: JavaSE-11 Import-Package: com.google.gson;version="[2.8.2,3.0.0)", com.google.gson.stream;version="[2.8.2,3.0.0)", - org.eclipse.jgit.annotations;version="[6.5.1,6.6.0)";resolution:=optional, - org.eclipse.jgit.api.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.attributes;version="[6.5.1,6.6.0)", - org.eclipse.jgit.diff;version="[6.5.1,6.6.0)", - org.eclipse.jgit.dircache;version="[6.5.1,6.6.0)", - org.eclipse.jgit.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.hooks;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.file;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.nls;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revwalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.storage.file;version="[6.5.1,6.6.0)", - org.eclipse.jgit.storage.pack;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.http;version="[6.5.1,6.6.0)", - org.eclipse.jgit.treewalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.treewalk.filter;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util.io;version="[6.5.1,6.6.0)" + org.eclipse.jgit.annotations;version="[6.6.0,6.7.0)";resolution:=optional, + org.eclipse.jgit.api.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.attributes;version="[6.6.0,6.7.0)", + org.eclipse.jgit.diff;version="[6.6.0,6.7.0)", + org.eclipse.jgit.dircache;version="[6.6.0,6.7.0)", + org.eclipse.jgit.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.hooks;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.file;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.nls;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revwalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.storage.file;version="[6.6.0,6.7.0)", + org.eclipse.jgit.storage.pack;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.http;version="[6.6.0,6.7.0)", + org.eclipse.jgit.treewalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.treewalk.filter;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util.io;version="[6.6.0,6.7.0)" diff --git a/org.eclipse.jgit.lfs/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.lfs/META-INF/SOURCE-MANIFEST.MF index 8525bf5243..05e9544840 100644 --- a/org.eclipse.jgit.lfs/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.lfs/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.lfs - Sources Bundle-SymbolicName: org.eclipse.jgit.lfs.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.5.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.lfs;version="6.5.1.qualifier";roots="." +Bundle-Version: 6.6.0.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.lfs;version="6.6.0.qualifier";roots="." diff --git a/org.eclipse.jgit.lfs/pom.xml b/org.eclipse.jgit.lfs/pom.xml index 0279b22d9d..b210bad2fe 100644 --- a/org.eclipse.jgit.lfs/pom.xml +++ b/org.eclipse.jgit.lfs/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.lfs</artifactId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.feature/feature.xml index 062b3a49d4..e559d21df9 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit" label="%featureName" - version="6.5.1.qualifier" + version="6.6.0.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.feature/pom.xml index 213017822b..b78e579293 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.gpg.bc.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.gpg.bc.feature/feature.xml index 74758c66c3..a69fafcafb 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.gpg.bc.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.gpg.bc.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit.gpg.bc" label="%featureName" - version="6.5.1.qualifier" + version="6.6.0.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> @@ -23,7 +23,7 @@ </url> <requires> - <import plugin="org.eclipse.jgit" version="6.5.1" match="equivalent"/> + <import plugin="org.eclipse.jgit" version="6.6.0" match="equivalent"/> </requires> <plugin diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.gpg.bc.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.gpg.bc.feature/pom.xml index ccf9325791..20767bf14c 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.gpg.bc.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.gpg.bc.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.http.apache.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.http.apache.feature/feature.xml index 415b11150e..76359c8c5c 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.http.apache.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.http.apache.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit.http.apache" label="%featureName" - version="6.5.1.qualifier" + version="6.6.0.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> @@ -23,7 +23,7 @@ </url> <requires> - <import plugin="org.eclipse.jgit" version="6.5.1" match="equivalent"/> + <import plugin="org.eclipse.jgit" version="6.6.0" match="equivalent"/> </requires> <plugin diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.http.apache.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.http.apache.feature/pom.xml index d48944dfb1..c94712ffec 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.http.apache.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.http.apache.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.junit.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.junit.feature/feature.xml index 5d3b1c4b36..881c72d7da 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.junit.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.junit.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit.junit" label="%featureName" - version="6.5.1.qualifier" + version="6.6.0.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> @@ -24,7 +24,7 @@ <requires> <import plugin="com.jcraft.jsch"/> - <import plugin="org.eclipse.jgit" version="6.5.1" match="equivalent"/> + <import plugin="org.eclipse.jgit" version="6.6.0" match="equivalent"/> </requires> <plugin diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.junit.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.junit.feature/pom.xml index 4f3be7a2a4..63f12d4c8b 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.junit.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.junit.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.lfs.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.lfs.feature/feature.xml index beb0f9b595..e77d20f13c 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.lfs.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.lfs.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit.lfs" label="%featureName" - version="6.5.1.qualifier" + version="6.6.0.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> @@ -23,7 +23,7 @@ </url> <requires> - <import feature="org.eclipse.jgit" version="6.5.1" match="equivalent"/> + <import feature="org.eclipse.jgit" version="6.6.0" match="equivalent"/> </requires> <plugin diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.lfs.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.lfs.feature/pom.xml index 35276dd765..1008b62108 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.lfs.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.lfs.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.pgm.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.pgm.feature/feature.xml index 6ccd1000a9..d65cb5a09b 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.pgm.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.pgm.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit.pgm" label="%featureName" - version="6.5.1.qualifier" + version="6.6.0.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> @@ -35,9 +35,9 @@ version="0.0.0"/> <requires> - <import feature="org.eclipse.jgit" version="6.5.1" match="equivalent"/> - <import feature="org.eclipse.jgit.lfs" version="6.5.1" match="equivalent"/> - <import feature="org.eclipse.jgit.ssh.apache" version="6.5.1" match="equivalent"/> + <import feature="org.eclipse.jgit" version="6.6.0" match="equivalent"/> + <import feature="org.eclipse.jgit.lfs" version="6.6.0" match="equivalent"/> + <import feature="org.eclipse.jgit.ssh.apache" version="6.6.0" match="equivalent"/> </requires> <plugin diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.pgm.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.pgm.feature/pom.xml index ef1b0b8b05..47e3bdabff 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.pgm.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.pgm.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.repository/category.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.repository/category.xml index 7fa2b837e7..3e4ce59ec0 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.repository/category.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.repository/category.xml @@ -177,28 +177,28 @@ <bundle id="org.apache.sshd.sftp.source"> <category name="JGit-dependency-bundles"/> </bundle> - <bundle id="org.bouncycastle.bcpg"> + <bundle id="bcpg"> <category name="JGit-dependency-bundles"/> </bundle> - <bundle id="org.bouncycastle.bcpg.source"> + <bundle id="bcpg.source"> <category name="JGit-dependency-bundles"/> </bundle> - <bundle id="org.bouncycastle.bcpkix"> + <bundle id="bcpkix"> <category name="JGit-dependency-bundles"/> </bundle> - <bundle id="org.bouncycastle.bcpkix.source"> + <bundle id="bcpkix.source"> <category name="JGit-dependency-bundles"/> </bundle> - <bundle id="org.bouncycastle.bcprov"> + <bundle id="bcprov"> <category name="JGit-dependency-bundles"/> </bundle> - <bundle id="org.bouncycastle.bcprov.source"> + <bundle id="bcprov.source"> <category name="JGit-dependency-bundles"/> </bundle> - <bundle id="org.bouncycastle.bcutil"> + <bundle id="bcutil"> <category name="JGit-dependency-bundles"/> </bundle> - <bundle id="org.bouncycastle.bcutil.source"> + <bundle id="bcutil.source"> <category name="JGit-dependency-bundles"/> </bundle> <bundle id="org.kohsuke.args4j"> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.repository/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.repository/pom.xml index f45cb5a70e..2a127bc9b6 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.repository/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.repository/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.repository</artifactId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.source.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.source.feature/feature.xml index 7075f20e0b..5d28c4c5c2 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.source.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.source.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit.source" label="%featureName" - version="6.5.1.qualifier" + version="6.6.0.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> @@ -23,7 +23,7 @@ </url> <requires> - <import feature="org.eclipse.jgit" version="6.5.1" match="equivalent"/> + <import feature="org.eclipse.jgit" version="6.6.0" match="equivalent"/> </requires> <plugin diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.source.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.source.feature/pom.xml index e49802b59f..abf6a30dbc 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.source.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.source.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> @@ -30,7 +30,7 @@ <dependency> <groupId>org.eclipse.jgit.feature</groupId> <artifactId>org.eclipse.jgit</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </dependency> </dependencies> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.apache.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.apache.feature/feature.xml index c9514f4d90..668dd0fe1a 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.apache.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.apache.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit.ssh.apache" label="%featureName" - version="6.5.1.qualifier" + version="6.6.0.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> @@ -23,7 +23,7 @@ </url> <requires> - <import feature="org.eclipse.jgit" version="6.5.1" match="equivalent"/> + <import feature="org.eclipse.jgit" version="6.6.0" match="equivalent"/> </requires> <plugin diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.apache.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.apache.feature/pom.xml index 60e984c48d..e507fabe3e 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.apache.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.apache.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.jsch.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.jsch.feature/feature.xml index f39c18a4eb..c4ac557ff8 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.jsch.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.jsch.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit.ssh.jsch" label="%featureName" - version="6.5.1.qualifier" + version="6.6.0.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> @@ -23,7 +23,7 @@ </url> <requires> - <import plugin="org.eclipse.jgit" version="6.5.1" match="equivalent"/> + <import plugin="org.eclipse.jgit" version="6.6.0" match="equivalent"/> </requires> <plugin diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.jsch.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.jsch.feature/pom.xml index 80e21c1324..c8ef056293 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.jsch.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.jsch.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/META-INF/MANIFEST.MF b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/META-INF/MANIFEST.MF index 8b87530c28..5b05303353 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/META-INF/MANIFEST.MF @@ -2,4 +2,4 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: JGit Target Platform Bundle Bundle-SymbolicName: org.eclipse.jgit.target -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.17.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.17.target index b4ad428ef4..e15d9b756e 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.17.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.17.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.17" sequenceNumber="1677748416"> +<target name="jgit-4.17" sequenceNumber="1681685282"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="org.eclipse.jetty.http" version="10.0.13"/> @@ -55,14 +55,6 @@ <unit id="org.apache.sshd.sftp.source" version="2.9.2.v20221117-1942"/> <unit id="org.assertj" version="3.20.2.v20210706-1104"/> <unit id="org.assertj.source" version="3.20.2.v20210706-1104"/> - <unit id="org.bouncycastle.bcpg" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpg.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil.source" version="1.72.0.v20221013-1810"/> <unit id="org.hamcrest" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.source" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.core" version="1.3.0.v20180420-1519"/> @@ -89,5 +81,33 @@ <unit id="org.eclipse.osgi" version="0.0.0"/> <repository location="https://download.eclipse.org/releases/2020-09/"/> </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.72.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + </dependencies> + </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.17.tpd b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.17.tpd index cf00c96a66..1038f277c9 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.17.tpd +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.17.tpd @@ -2,6 +2,7 @@ target "jgit-4.17" with source configurePhase include "projects/jetty-10.0.x.tpd" include "orbit/R20230302014618-2023-03.tpd" +include "maven/dependencies.tpd" location "https://download.eclipse.org/releases/2020-09/" { org.eclipse.osgi lazy diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.18.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.18.target index 9ad44d8113..89f4fb3c57 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.18.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.18.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.18" sequenceNumber="1677748416"> +<target name="jgit-4.18" sequenceNumber="1681685282"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="org.eclipse.jetty.http" version="10.0.13"/> @@ -55,14 +55,6 @@ <unit id="org.apache.sshd.sftp.source" version="2.9.2.v20221117-1942"/> <unit id="org.assertj" version="3.20.2.v20210706-1104"/> <unit id="org.assertj.source" version="3.20.2.v20210706-1104"/> - <unit id="org.bouncycastle.bcpg" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpg.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil.source" version="1.72.0.v20221013-1810"/> <unit id="org.hamcrest" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.source" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.core" version="1.3.0.v20180420-1519"/> @@ -89,5 +81,33 @@ <unit id="org.eclipse.osgi" version="0.0.0"/> <repository location="https://download.eclipse.org/releases/2020-12/"/> </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.72.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + </dependencies> + </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.18.tpd b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.18.tpd index 325b6de84a..2bd7eb7c71 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.18.tpd +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.18.tpd @@ -2,6 +2,7 @@ target "jgit-4.18" with source configurePhase include "projects/jetty-10.0.x.tpd" include "orbit/R20230302014618-2023-03.tpd" +include "maven/dependencies.tpd" location "https://download.eclipse.org/releases/2020-12/" { org.eclipse.osgi lazy diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.19.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.19.target index e570bf9a54..52839196a7 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.19.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.19.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.19-staging" sequenceNumber="1677748416"> +<target name="jgit-4.19-staging" sequenceNumber="1681685282"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="org.eclipse.jetty.http" version="10.0.13"/> @@ -55,14 +55,6 @@ <unit id="org.apache.sshd.sftp.source" version="2.9.2.v20221117-1942"/> <unit id="org.assertj" version="3.20.2.v20210706-1104"/> <unit id="org.assertj.source" version="3.20.2.v20210706-1104"/> - <unit id="org.bouncycastle.bcpg" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpg.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil.source" version="1.72.0.v20221013-1810"/> <unit id="org.hamcrest" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.source" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.core" version="1.3.0.v20180420-1519"/> @@ -89,5 +81,33 @@ <unit id="org.eclipse.osgi" version="0.0.0"/> <repository location="https://download.eclipse.org/releases/2021-03/"/> </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.72.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + </dependencies> + </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.19.tpd b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.19.tpd index 08f3910289..e5528241a4 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.19.tpd +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.19.tpd @@ -2,6 +2,7 @@ target "jgit-4.19-staging" with source configurePhase include "projects/jetty-10.0.x.tpd" include "orbit/R20230302014618-2023-03.tpd" +include "maven/dependencies.tpd" location "https://download.eclipse.org/releases/2021-03/" { org.eclipse.osgi lazy diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.20.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.20.target index a3f7c2b639..2ddc2f51a1 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.20.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.20.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.20" sequenceNumber="1677748416"> +<target name="jgit-4.20" sequenceNumber="1681685281"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="org.eclipse.jetty.http" version="10.0.13"/> @@ -55,14 +55,6 @@ <unit id="org.apache.sshd.sftp.source" version="2.9.2.v20221117-1942"/> <unit id="org.assertj" version="3.20.2.v20210706-1104"/> <unit id="org.assertj.source" version="3.20.2.v20210706-1104"/> - <unit id="org.bouncycastle.bcpg" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpg.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil.source" version="1.72.0.v20221013-1810"/> <unit id="org.hamcrest" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.source" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.core" version="1.3.0.v20180420-1519"/> @@ -89,5 +81,33 @@ <unit id="org.eclipse.osgi" version="0.0.0"/> <repository location="https://download.eclipse.org/releases/2021-06/"/> </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.72.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + </dependencies> + </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.20.tpd b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.20.tpd index 07f8ab5d8a..b915cd1910 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.20.tpd +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.20.tpd @@ -2,6 +2,7 @@ target "jgit-4.20" with source configurePhase include "projects/jetty-10.0.x.tpd" include "orbit/R20230302014618-2023-03.tpd" +include "maven/dependencies.tpd" location "https://download.eclipse.org/releases/2021-06/" { org.eclipse.osgi lazy diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.21.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.21.target index 908087fe6c..c67a3b9312 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.21.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.21.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.21" sequenceNumber="1677748416"> +<target name="jgit-4.21" sequenceNumber="1681685282"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="org.eclipse.jetty.http" version="10.0.13"/> @@ -55,14 +55,6 @@ <unit id="org.apache.sshd.sftp.source" version="2.9.2.v20221117-1942"/> <unit id="org.assertj" version="3.20.2.v20210706-1104"/> <unit id="org.assertj.source" version="3.20.2.v20210706-1104"/> - <unit id="org.bouncycastle.bcpg" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpg.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil.source" version="1.72.0.v20221013-1810"/> <unit id="org.hamcrest" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.source" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.core" version="1.3.0.v20180420-1519"/> @@ -89,5 +81,33 @@ <unit id="org.eclipse.osgi" version="0.0.0"/> <repository location="https://download.eclipse.org/releases/2021-09/"/> </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.72.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + </dependencies> + </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.21.tpd b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.21.tpd index c957b85ff2..179efb7e2a 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.21.tpd +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.21.tpd @@ -2,6 +2,7 @@ target "jgit-4.21" with source configurePhase include "projects/jetty-10.0.x.tpd" include "orbit/R20230302014618-2023-03.tpd" +include "maven/dependencies.tpd" location "https://download.eclipse.org/releases/2021-09/" { org.eclipse.osgi lazy diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.22.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.22.target index b07928441e..636f58aa0e 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.22.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.22.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.22" sequenceNumber="1677748416"> +<target name="jgit-4.22" sequenceNumber="1681685281"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="org.eclipse.jetty.http" version="10.0.13"/> @@ -55,14 +55,6 @@ <unit id="org.apache.sshd.sftp.source" version="2.9.2.v20221117-1942"/> <unit id="org.assertj" version="3.20.2.v20210706-1104"/> <unit id="org.assertj.source" version="3.20.2.v20210706-1104"/> - <unit id="org.bouncycastle.bcpg" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpg.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil.source" version="1.72.0.v20221013-1810"/> <unit id="org.hamcrest" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.source" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.core" version="1.3.0.v20180420-1519"/> @@ -89,5 +81,33 @@ <unit id="org.eclipse.osgi" version="0.0.0"/> <repository location="https://download.eclipse.org/releases/2021-12/"/> </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.72.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + </dependencies> + </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.22.tpd b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.22.tpd index 61a16da2aa..fe6cfb7d64 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.22.tpd +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.22.tpd @@ -2,6 +2,7 @@ target "jgit-4.22" with source configurePhase include "projects/jetty-10.0.x.tpd" include "orbit/R20230302014618-2023-03.tpd" +include "maven/dependencies.tpd" location "https://download.eclipse.org/releases/2021-12/" { org.eclipse.osgi lazy diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.23.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.23.target index e85e43d50d..cf677f79a1 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.23.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.23.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.23" sequenceNumber="1677748416"> +<target name="jgit-4.23" sequenceNumber="1681685281"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="org.eclipse.jetty.http" version="10.0.13"/> @@ -55,14 +55,6 @@ <unit id="org.apache.sshd.sftp.source" version="2.9.2.v20221117-1942"/> <unit id="org.assertj" version="3.20.2.v20210706-1104"/> <unit id="org.assertj.source" version="3.20.2.v20210706-1104"/> - <unit id="org.bouncycastle.bcpg" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpg.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil.source" version="1.72.0.v20221013-1810"/> <unit id="org.hamcrest" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.source" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.core" version="1.3.0.v20180420-1519"/> @@ -89,5 +81,33 @@ <unit id="org.eclipse.osgi" version="0.0.0"/> <repository location="https://download.eclipse.org/releases/2022-03/"/> </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.72.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + </dependencies> + </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.23.tpd b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.23.tpd index fde3bb65ec..d7c2d5ff1b 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.23.tpd +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.23.tpd @@ -2,6 +2,7 @@ target "jgit-4.23" with source configurePhase include "projects/jetty-10.0.x.tpd" include "orbit/R20230302014618-2023-03.tpd" +include "maven/dependencies.tpd" location "https://download.eclipse.org/releases/2022-03/" { org.eclipse.osgi lazy diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.24.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.24.target index 51d8fd5995..5d851fa779 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.24.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.24.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.24" sequenceNumber="1677748416"> +<target name="jgit-4.24" sequenceNumber="1681685281"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="org.eclipse.jetty.http" version="10.0.13"/> @@ -55,14 +55,6 @@ <unit id="org.apache.sshd.sftp.source" version="2.9.2.v20221117-1942"/> <unit id="org.assertj" version="3.20.2.v20210706-1104"/> <unit id="org.assertj.source" version="3.20.2.v20210706-1104"/> - <unit id="org.bouncycastle.bcpg" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpg.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil.source" version="1.72.0.v20221013-1810"/> <unit id="org.hamcrest" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.source" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.core" version="1.3.0.v20180420-1519"/> @@ -89,5 +81,33 @@ <unit id="org.eclipse.osgi" version="0.0.0"/> <repository location="https://download.eclipse.org/releases/2022-06/"/> </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.72.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + </dependencies> + </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.24.tpd b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.24.tpd index 6c480c3ca9..d8815ddef0 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.24.tpd +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.24.tpd @@ -2,6 +2,7 @@ target "jgit-4.24" with source configurePhase include "projects/jetty-10.0.x.tpd" include "orbit/R20230302014618-2023-03.tpd" +include "maven/dependencies.tpd" location "https://download.eclipse.org/releases/2022-06/" { org.eclipse.osgi lazy diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.25.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.25.target index b7260bffbe..db5de42848 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.25.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.25.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.25" sequenceNumber="1677748416"> +<target name="jgit-4.25" sequenceNumber="1681685281"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="org.eclipse.jetty.http" version="10.0.13"/> @@ -55,14 +55,6 @@ <unit id="org.apache.sshd.sftp.source" version="2.9.2.v20221117-1942"/> <unit id="org.assertj" version="3.20.2.v20210706-1104"/> <unit id="org.assertj.source" version="3.20.2.v20210706-1104"/> - <unit id="org.bouncycastle.bcpg" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpg.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil.source" version="1.72.0.v20221013-1810"/> <unit id="org.hamcrest" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.source" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.core" version="1.3.0.v20180420-1519"/> @@ -89,5 +81,33 @@ <unit id="org.eclipse.osgi" version="0.0.0"/> <repository location="https://download.eclipse.org/releases/2022-09/"/> </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.72.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + </dependencies> + </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.25.tpd b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.25.tpd index 4542b13258..6f72107983 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.25.tpd +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.25.tpd @@ -2,6 +2,7 @@ target "jgit-4.25" with source configurePhase include "projects/jetty-10.0.x.tpd" include "orbit/R20230302014618-2023-03.tpd" +include "maven/dependencies.tpd" location "https://download.eclipse.org/releases/2022-09/" { org.eclipse.osgi lazy diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.26.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.26.target index 57c9d0d41e..6b57652a2b 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.26.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.26.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.26" sequenceNumber="1677748097"> +<target name="jgit-4.26" sequenceNumber="1681685281"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="org.eclipse.jetty.http" version="10.0.13"/> @@ -55,14 +55,6 @@ <unit id="org.apache.sshd.sftp.source" version="2.9.2.v20221117-1942"/> <unit id="org.assertj" version="3.20.2.v20210706-1104"/> <unit id="org.assertj.source" version="3.20.2.v20210706-1104"/> - <unit id="org.bouncycastle.bcpg" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpg.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcpkix.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcprov.source" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil" version="1.72.0.v20221013-1810"/> - <unit id="org.bouncycastle.bcutil.source" version="1.72.0.v20221013-1810"/> <unit id="org.hamcrest" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.source" version="2.2.0.v20210711-0821"/> <unit id="org.hamcrest.core" version="1.3.0.v20180420-1519"/> @@ -89,5 +81,33 @@ <unit id="org.eclipse.osgi" version="0.0.0"/> <repository location="https://download.eclipse.org/releases/2022-12/"/> </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.72.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.72</version> + <type>jar</type> + </dependency> + </dependencies> + </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.26.tpd b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.26.tpd index 25a223ab60..d80e5bf8ec 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.26.tpd +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.26.tpd @@ -2,6 +2,7 @@ target "jgit-4.26" with source configurePhase include "projects/jetty-10.0.x.tpd" include "orbit/R20230302014618-2023-03.tpd" +include "maven/dependencies.tpd" location "https://download.eclipse.org/releases/2022-12/" { org.eclipse.osgi lazy diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/maven/dependencies.tpd b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/maven/dependencies.tpd new file mode 100644 index 0000000000..9f2220fd98 --- /dev/null +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/maven/dependencies.tpd @@ -0,0 +1,29 @@ +target "dependencies" + +maven bouncycastle + scope = compile + dependencyDepth = none + missingManifest = error + includeSources +{ + dependency { + groupId = "org.bouncycastle" + artifactId = "bcpg-jdk18on" + version = "1.72.2" + } + dependency { + groupId = "org.bouncycastle" + artifactId = "bcprov-jdk18on" + version = "1.72" + } + dependency { + groupId = "org.bouncycastle" + artifactId = "bcpkix-jdk18on" + version = "1.72" + } + dependency { + groupId = "org.bouncycastle" + artifactId = "bcutil-jdk18on" + version = "1.72" + } +} diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/orbit/R20230302014618-2023-03.tpd b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/orbit/R20230302014618-2023-03.tpd index ad29378af0..3712d0af0d 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/orbit/R20230302014618-2023-03.tpd +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/orbit/R20230302014618-2023-03.tpd @@ -38,14 +38,6 @@ location "https://download.eclipse.org/tools/orbit/downloads/drops/R202303020146 org.apache.sshd.sftp.source [2.9.2.v20221117-1942,2.9.2.v20221117-1942] org.assertj [3.20.2.v20210706-1104,3.20.2.v20210706-1104] org.assertj.source [3.20.2.v20210706-1104,3.20.2.v20210706-1104] - org.bouncycastle.bcpg [1.72.0.v20221013-1810,1.72.0.v20221013-1810] - org.bouncycastle.bcpg.source [1.72.0.v20221013-1810,1.72.0.v20221013-1810] - org.bouncycastle.bcpkix [1.72.0.v20221013-1810,1.72.0.v20221013-1810] - org.bouncycastle.bcpkix.source [1.72.0.v20221013-1810,1.72.0.v20221013-1810] - org.bouncycastle.bcprov [1.72.0.v20221013-1810,1.72.0.v20221013-1810] - org.bouncycastle.bcprov.source [1.72.0.v20221013-1810,1.72.0.v20221013-1810] - org.bouncycastle.bcutil [1.72.0.v20221013-1810,1.72.0.v20221013-1810] - org.bouncycastle.bcutil.source [1.72.0.v20221013-1810,1.72.0.v20221013-1810] org.hamcrest [2.2.0.v20210711-0821,2.2.0.v20210711-0821] org.hamcrest.source [2.2.0.v20210711-0821,2.2.0.v20210711-0821] org.hamcrest.core [1.3.0.v20180420-1519,1.3.0.v20180420-1519] diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/pom.xml index 8945542428..d83d1bd559 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/pom.xml @@ -16,7 +16,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.target</artifactId> diff --git a/org.eclipse.jgit.packaging/pom.xml b/org.eclipse.jgit.packaging/pom.xml index 28ae7ceb2c..eae7145871 100644 --- a/org.eclipse.jgit.packaging/pom.xml +++ b/org.eclipse.jgit.packaging/pom.xml @@ -16,7 +16,7 @@ <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> <packaging>pom</packaging> <name>JGit Tycho Parent</name> diff --git a/org.eclipse.jgit.pgm.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.pgm.test/META-INF/MANIFEST.MF index a309b710b2..181e19f951 100644 --- a/org.eclipse.jgit.pgm.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.pgm.test/META-INF/MANIFEST.MF @@ -3,30 +3,30 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.pgm.test Bundle-SymbolicName: org.eclipse.jgit.pgm.test -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-ActivationPolicy: lazy Bundle-RequiredExecutionEnvironment: JavaSE-11 -Import-Package: org.eclipse.jgit.api;version="[6.5.1,6.6.0)", - org.eclipse.jgit.api.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.diff;version="[6.5.1,6.6.0)", - org.eclipse.jgit.dircache;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.diffmergetool;version="6.5.1", - org.eclipse.jgit.internal.storage.file;version="6.5.1", - org.eclipse.jgit.junit;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib.internal;version="[6.5.1,6.6.0)", - org.eclipse.jgit.merge;version="[6.5.1,6.6.0)", - org.eclipse.jgit.pgm;version="[6.5.1,6.6.0)", - org.eclipse.jgit.pgm.internal;version="[6.5.1,6.6.0)", - org.eclipse.jgit.pgm.opt;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revwalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.storage.file;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport;version="[6.5.1,6.6.0)", - org.eclipse.jgit.treewalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util.io;version="[6.5.1,6.6.0)", +Import-Package: org.eclipse.jgit.api;version="[6.6.0,6.7.0)", + org.eclipse.jgit.api.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.diff;version="[6.6.0,6.7.0)", + org.eclipse.jgit.dircache;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.diffmergetool;version="6.6.0", + org.eclipse.jgit.internal.storage.file;version="6.6.0", + org.eclipse.jgit.junit;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib.internal;version="[6.6.0,6.7.0)", + org.eclipse.jgit.merge;version="[6.6.0,6.7.0)", + org.eclipse.jgit.pgm;version="[6.6.0,6.7.0)", + org.eclipse.jgit.pgm.internal;version="[6.6.0,6.7.0)", + org.eclipse.jgit.pgm.opt;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revwalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.storage.file;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport;version="[6.6.0,6.7.0)", + org.eclipse.jgit.treewalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util.io;version="[6.6.0,6.7.0)", org.hamcrest.core;bundle-version="[1.1.0,3.0.0)", org.junit;version="[4.13,5.0.0)", org.junit.rules;version="[4.13,5.0.0)", diff --git a/org.eclipse.jgit.pgm.test/pom.xml b/org.eclipse.jgit.pgm.test/pom.xml index 86d6cc986e..f035294531 100644 --- a/org.eclipse.jgit.pgm.test/pom.xml +++ b/org.eclipse.jgit.pgm.test/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.pgm.test</artifactId> diff --git a/org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/TagTest.java b/org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/TagTest.java index e8d61a520c..26d617dd81 100644 --- a/org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/TagTest.java +++ b/org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/TagTest.java @@ -9,24 +9,30 @@ */ package org.eclipse.jgit.pgm; +import static org.junit.Assert.assertArrayEquals; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNotNull; import static org.junit.Assert.assertNull; import org.eclipse.jgit.api.Git; +import org.eclipse.jgit.junit.TestRepository; import org.eclipse.jgit.lib.CLIRepositoryTestCase; +import org.eclipse.jgit.lib.Repository; +import org.eclipse.jgit.revwalk.RevCommit; import org.junit.Before; import org.junit.Test; public class TagTest extends CLIRepositoryTestCase { private Git git; + private RevCommit initialCommit; + @Override @Before public void setUp() throws Exception { super.setUp(); git = new Git(db); - git.commit().setMessage("initial commit").call(); + initialCommit = git.commit().setMessage("initial commit").call(); } @Test @@ -57,4 +63,39 @@ public class TagTest extends CLIRepositoryTestCase { assertEquals("fatal: error: tag 'test' not found", e.getMessage()); } } + + @Test + public void testContains() throws Exception { + /* c3 + * | + * v2 - c2 b2 - v1 + * | | + * c1 b1 + * \ / + * a + */ + try (TestRepository<Repository> r = new TestRepository<>( + db)) { + RevCommit b1 = r.commit(initialCommit); + RevCommit b2 = r.commit(b1); + RevCommit c1 = r.commit(initialCommit); + RevCommit c2 = r.commit(c1); + RevCommit c3 = r.commit(c2); + r.update("refs/tags/v1", r.tag("v1", b2)); + r.update("refs/tags/v2", r.tag("v1.1", c2)); + + assertArrayEquals( + new String[] { "v1", "v2", "" }, + execute("git tag --contains " + initialCommit.name())); + + assertArrayEquals(new String[] { "v1", "" }, + execute("git tag --contains " + b1.name())); + + assertArrayEquals(new String[] { "v2", "" }, + execute("git tag --contains " + c1.name())); + + assertArrayEquals(new String[] { "" }, + execute("git tag --contains " + c3.name())); + } + } } diff --git a/org.eclipse.jgit.pgm/META-INF/MANIFEST.MF b/org.eclipse.jgit.pgm/META-INF/MANIFEST.MF index 5399d7de4d..de163817b4 100644 --- a/org.eclipse.jgit.pgm/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.pgm/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.pgm Bundle-SymbolicName: org.eclipse.jgit.pgm -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-11 @@ -14,49 +14,49 @@ Import-Package: javax.servlet;version="[3.1.0,5.0.0)", org.eclipse.jetty.servlet;version="[10.0.0,11.0.0)", org.eclipse.jetty.util;version="[10.0.0,11.0.0)", org.eclipse.jetty.util.component;version="[10.0.0,11.0.0)", - org.eclipse.jgit.api;version="[6.5.1,6.6.0)", - org.eclipse.jgit.api.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.archive;version="[6.5.1,6.6.0)", - org.eclipse.jgit.awtui;version="[6.5.1,6.6.0)", - org.eclipse.jgit.blame;version="[6.5.1,6.6.0)", - org.eclipse.jgit.diff;version="[6.5.1,6.6.0)", - org.eclipse.jgit.dircache;version="[6.5.1,6.6.0)", - org.eclipse.jgit.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.gitrepo;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.file;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.diffmergetool;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.io;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.pack;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.reftable;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs.server;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs.server.fs;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs.server.s3;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.merge;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib.internal;version="[6.5.1,6.6.0)", - org.eclipse.jgit.nls;version="[6.5.1,6.6.0)", - org.eclipse.jgit.notes;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revplot;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revwalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revwalk.filter;version="[6.5.1,6.6.0)", - org.eclipse.jgit.storage.file;version="[6.5.1,6.6.0)", - org.eclipse.jgit.storage.pack;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.http.apache;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.resolver;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.ssh.jsch;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.sshd;version="[6.5.1,6.6.0)", - org.eclipse.jgit.treewalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.treewalk.filter;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util.io;version="[6.5.1,6.6.0)", + org.eclipse.jgit.api;version="[6.6.0,6.7.0)", + org.eclipse.jgit.api.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.archive;version="[6.6.0,6.7.0)", + org.eclipse.jgit.awtui;version="[6.6.0,6.7.0)", + org.eclipse.jgit.blame;version="[6.6.0,6.7.0)", + org.eclipse.jgit.diff;version="[6.6.0,6.7.0)", + org.eclipse.jgit.dircache;version="[6.6.0,6.7.0)", + org.eclipse.jgit.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.gitrepo;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.file;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.diffmergetool;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.io;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.pack;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.reftable;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs.server;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs.server.fs;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs.server.s3;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.merge;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib.internal;version="[6.6.0,6.7.0)", + org.eclipse.jgit.nls;version="[6.6.0,6.7.0)", + org.eclipse.jgit.notes;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revplot;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revwalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revwalk.filter;version="[6.6.0,6.7.0)", + org.eclipse.jgit.storage.file;version="[6.6.0,6.7.0)", + org.eclipse.jgit.storage.pack;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.http.apache;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.resolver;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.ssh.jsch;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.sshd;version="[6.6.0,6.7.0)", + org.eclipse.jgit.treewalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.treewalk.filter;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util.io;version="[6.6.0,6.7.0)", org.kohsuke.args4j;version="[2.33.0,3.0.0)", org.kohsuke.args4j.spi;version="[2.33.0,3.0.0)" -Export-Package: org.eclipse.jgit.console;version="6.5.1"; +Export-Package: org.eclipse.jgit.console;version="6.6.0"; uses:="org.eclipse.jgit.transport, org.eclipse.jgit.util", - org.eclipse.jgit.pgm;version="6.5.1"; + org.eclipse.jgit.pgm;version="6.6.0"; uses:="org.eclipse.jgit.transport, org.eclipse.jgit.util.io, org.eclipse.jgit.awtui, @@ -68,14 +68,14 @@ Export-Package: org.eclipse.jgit.console;version="6.5.1"; org.eclipse.jgit.treewalk, org.eclipse.jgit.api, javax.swing", - org.eclipse.jgit.pgm.debug;version="6.5.1"; + org.eclipse.jgit.pgm.debug;version="6.6.0"; uses:="org.eclipse.jgit.util.io, org.eclipse.jgit.pgm, org.eclipse.jetty.servlet", - org.eclipse.jgit.pgm.internal;version="6.5.1"; + org.eclipse.jgit.pgm.internal;version="6.6.0"; x-friends:="org.eclipse.jgit.pgm.test, org.eclipse.jgit.test", - org.eclipse.jgit.pgm.opt;version="6.5.1"; + org.eclipse.jgit.pgm.opt;version="6.6.0"; uses:="org.kohsuke.args4j, org.eclipse.jgit.lib, org.eclipse.jgit.revwalk, diff --git a/org.eclipse.jgit.pgm/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.pgm/META-INF/SOURCE-MANIFEST.MF index 22414257c3..721d818621 100644 --- a/org.eclipse.jgit.pgm/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.pgm/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.pgm - Sources Bundle-SymbolicName: org.eclipse.jgit.pgm.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.5.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.pgm;version="6.5.1.qualifier";roots="." +Bundle-Version: 6.6.0.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.pgm;version="6.6.0.qualifier";roots="." diff --git a/org.eclipse.jgit.pgm/pom.xml b/org.eclipse.jgit.pgm/pom.xml index a45c2b1c04..e4871ac5be 100644 --- a/org.eclipse.jgit.pgm/pom.xml +++ b/org.eclipse.jgit.pgm/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.pgm</artifactId> diff --git a/org.eclipse.jgit.pgm/resources/org/eclipse/jgit/pgm/internal/CLIText.properties b/org.eclipse.jgit.pgm/resources/org/eclipse/jgit/pgm/internal/CLIText.properties index 98d711d0ff..7b81af59bc 100644 --- a/org.eclipse.jgit.pgm/resources/org/eclipse/jgit/pgm/internal/CLIText.properties +++ b/org.eclipse.jgit.pgm/resources/org/eclipse/jgit/pgm/internal/CLIText.properties @@ -469,6 +469,7 @@ usage_trustExitCode=git-difftool invokes a diff tool individually on each file. usage_noTrustExitCode=This option can be used to override --trust-exit-code setting. usage_notags=do not fetch tags usage_tagAnnotated=create an annotated tag, unsigned unless -s or -u are given, or config tag.gpgSign is true +usage_tagContains=Only list tags which contain the specified commit usage_tagDelete=delete tag usage_tagLocalUser=create a signed annotated tag using the specified GPG key ID usage_tagMessage=create an annotated tag with the given message, unsigned unless -s or -u are given, or config tag.gpgSign is true, or tar.forceSignAnnotated is true and -a is not given diff --git a/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Tag.java b/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Tag.java index e2cd31d198..0603de18ac 100644 --- a/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Tag.java +++ b/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Tag.java @@ -33,6 +33,7 @@ import org.eclipse.jgit.lib.Ref; import org.eclipse.jgit.lib.Repository; import org.eclipse.jgit.pgm.internal.CLIText; import org.eclipse.jgit.pgm.internal.VerificationUtils; +import org.eclipse.jgit.revwalk.RevCommit; import org.eclipse.jgit.revwalk.RevTag; import org.eclipse.jgit.revwalk.RevWalk; import org.kohsuke.args4j.Argument; @@ -76,6 +77,11 @@ class Tag extends TextBuiltin { "--local-user" }, usage = "usage_tagVerify") private boolean verify; + @Option(name = "--contains", forbids = { "--delete", "--force", + "--annotate", "-m", "--sign", "--no-sign", + "--local-user" }, metaVar = "metaVar_commitish", usage = "usage_tagContains") + private RevCommit contains; + @Argument(index = 0, metaVar = "metaVar_name") private String tagName; @@ -142,6 +148,9 @@ class Tag extends TextBuiltin { } } else { ListTagCommand command = git.tagList(); + if (contains != null) { + command.setContains(contains); + } List<Ref> list = command.call(); for (Ref ref : list) { outw.println(Repository.shortenRefName(ref.getName())); diff --git a/org.eclipse.jgit.ssh.apache.agent/META-INF/MANIFEST.MF b/org.eclipse.jgit.ssh.apache.agent/META-INF/MANIFEST.MF index cce648654c..38b380f6b6 100644 --- a/org.eclipse.jgit.ssh.apache.agent/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.ssh.apache.agent/META-INF/MANIFEST.MF @@ -2,16 +2,16 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Bundle-SymbolicName: org.eclipse.jgit.ssh.apache.agent;singleton:=true -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Localization: plugin Bundle-Vendor: %Bundle-Vendor -Fragment-Host: org.eclipse.jgit.ssh.apache;bundle-version="[6.5.1,6.6.0)" +Fragment-Host: org.eclipse.jgit.ssh.apache;bundle-version="[6.6.0,6.7.0)" Bundle-ActivationPolicy: lazy Automatic-Module-Name: org.eclipse.jgit.ssh.apache.agent Bundle-RequiredExecutionEnvironment: JavaSE-11 -Import-Package: org.eclipse.jgit.transport.sshd;version="[6.5.1,6.6.0)", - org.eclipse.jgit.nls;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)" +Import-Package: org.eclipse.jgit.transport.sshd;version="[6.6.0,6.7.0)", + org.eclipse.jgit.nls;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)" Require-Bundle: com.sun.jna;bundle-version="[5.8.0,6.0.0)", com.sun.jna.platform;bundle-version="[5.8.0,6.0.0)" -Export-Package: org.eclipse.jgit.internal.transport.sshd.agent.connector;version="6.5.1";x-internal:=true +Export-Package: org.eclipse.jgit.internal.transport.sshd.agent.connector;version="6.6.0";x-internal:=true diff --git a/org.eclipse.jgit.ssh.apache.agent/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.ssh.apache.agent/META-INF/SOURCE-MANIFEST.MF index 303955422e..61749eb58c 100644 --- a/org.eclipse.jgit.ssh.apache.agent/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.ssh.apache.agent/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.ssh.apache.agent - Sources Bundle-SymbolicName: org.eclipse.jgit.ssh.apache.agent.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.5.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.ssh.apache.agent;version="6.5.1.qualifier";roots="." +Bundle-Version: 6.6.0.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.ssh.apache.agent;version="6.6.0.qualifier";roots="." diff --git a/org.eclipse.jgit.ssh.apache.agent/pom.xml b/org.eclipse.jgit.ssh.apache.agent/pom.xml index 200d5b7939..1b8a2a18fc 100644 --- a/org.eclipse.jgit.ssh.apache.agent/pom.xml +++ b/org.eclipse.jgit.ssh.apache.agent/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.ssh.apache.agent</artifactId> diff --git a/org.eclipse.jgit.ssh.apache.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.ssh.apache.test/META-INF/MANIFEST.MF index 22d957616c..1e74f2baee 100644 --- a/org.eclipse.jgit.ssh.apache.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.ssh.apache.test/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.ssh.apache.test Bundle-SymbolicName: org.eclipse.jgit.ssh.apache.test -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-11 @@ -21,16 +21,16 @@ Import-Package: org.apache.sshd.client.config.hosts;version="[2.9.2,2.10.0)", org.apache.sshd.core;version="[2.9.2,2.10.0)", org.apache.sshd.server;version="[2.9.2,2.10.0)", org.apache.sshd.server.forward;version="[2.9.2,2.10.0)", - org.eclipse.jgit.api;version="[6.5.1,6.6.0)", - org.eclipse.jgit.api.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.transport.sshd.proxy;version="[6.5.1,6.6.0)", - org.eclipse.jgit.junit;version="[6.5.1,6.6.0)", - org.eclipse.jgit.junit.ssh;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.sshd;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.sshd.agent;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)", + org.eclipse.jgit.api;version="[6.6.0,6.7.0)", + org.eclipse.jgit.api.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.transport.sshd.proxy;version="[6.6.0,6.7.0)", + org.eclipse.jgit.junit;version="[6.6.0,6.7.0)", + org.eclipse.jgit.junit.ssh;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.sshd;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.sshd.agent;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)", org.hamcrest;version="[1.1.0,3.0.0)", org.junit;version="[4.13,5.0.0)", org.junit.experimental.theories;version="[4.13,5.0.0)", diff --git a/org.eclipse.jgit.ssh.apache.test/pom.xml b/org.eclipse.jgit.ssh.apache.test/pom.xml index ec553f31bc..d7c2146371 100644 --- a/org.eclipse.jgit.ssh.apache.test/pom.xml +++ b/org.eclipse.jgit.ssh.apache.test/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.ssh.apache.test</artifactId> diff --git a/org.eclipse.jgit.ssh.apache/META-INF/MANIFEST.MF b/org.eclipse.jgit.ssh.apache/META-INF/MANIFEST.MF index a44ff2207a..83859e2eb6 100644 --- a/org.eclipse.jgit.ssh.apache/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.ssh.apache/META-INF/MANIFEST.MF @@ -6,9 +6,9 @@ Bundle-SymbolicName: org.eclipse.jgit.ssh.apache Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-ActivationPolicy: lazy -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-RequiredExecutionEnvironment: JavaSE-11 -Export-Package: org.eclipse.jgit.internal.transport.sshd;version="6.5.1";x-internal:=true; +Export-Package: org.eclipse.jgit.internal.transport.sshd;version="6.6.0";x-internal:=true; uses:="org.apache.sshd.client, org.apache.sshd.client.auth, org.apache.sshd.client.auth.keyboard, @@ -23,17 +23,17 @@ Export-Package: org.eclipse.jgit.internal.transport.sshd;version="6.5.1";x-inter org.apache.sshd.common.signature, org.apache.sshd.common.util.buffer, org.eclipse.jgit.transport", - org.eclipse.jgit.internal.transport.sshd.agent;version="6.5.1";x-internal:=true, - org.eclipse.jgit.internal.transport.sshd.auth;version="6.5.1";x-internal:=true, - org.eclipse.jgit.internal.transport.sshd.proxy;version="6.5.1";x-friends:="org.eclipse.jgit.ssh.apache.test", - org.eclipse.jgit.transport.sshd;version="6.5.1"; + org.eclipse.jgit.internal.transport.sshd.agent;version="6.6.0";x-internal:=true, + org.eclipse.jgit.internal.transport.sshd.auth;version="6.6.0";x-internal:=true, + org.eclipse.jgit.internal.transport.sshd.proxy;version="6.6.0";x-friends:="org.eclipse.jgit.ssh.apache.test", + org.eclipse.jgit.transport.sshd;version="6.6.0"; uses:="org.eclipse.jgit.transport, org.apache.sshd.client.config.hosts, org.apache.sshd.common.keyprovider, org.eclipse.jgit.util, org.apache.sshd.client.session, org.apache.sshd.client.keyverifier", - org.eclipse.jgit.transport.sshd.agent;version="6.5.1" + org.eclipse.jgit.transport.sshd.agent;version="6.6.0" Import-Package: net.i2p.crypto.eddsa;version="[0.3.0,0.4.0)", org.apache.sshd.agent;version="[2.9.2,2.10.0)", org.apache.sshd.client;version="[2.9.2,2.10.0)", @@ -86,12 +86,12 @@ Import-Package: net.i2p.crypto.eddsa;version="[0.3.0,0.4.0)", org.apache.sshd.sftp;version="[2.9.2,2.10.0)", org.apache.sshd.sftp.client;version="[2.9.2,2.10.0)", org.apache.sshd.sftp.common;version="[2.9.2,2.10.0)", - org.eclipse.jgit.annotations;version="[6.5.1,6.6.0)", - org.eclipse.jgit.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.fnmatch;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.file;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.transport.ssh;version="[6.5.1,6.6.0)", - org.eclipse.jgit.nls;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)", + org.eclipse.jgit.annotations;version="[6.6.0,6.7.0)", + org.eclipse.jgit.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.fnmatch;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.file;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.transport.ssh;version="[6.6.0,6.7.0)", + org.eclipse.jgit.nls;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)", org.slf4j;version="[1.7.0,2.0.0)" diff --git a/org.eclipse.jgit.ssh.apache/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.ssh.apache/META-INF/SOURCE-MANIFEST.MF index 7d5e247e40..b99eb425d5 100644 --- a/org.eclipse.jgit.ssh.apache/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.ssh.apache/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.ssh.apache - Sources Bundle-SymbolicName: org.eclipse.jgit.ssh.apache.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.5.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.ssh.apache;version="6.5.1.qualifier";roots="." +Bundle-Version: 6.6.0.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.ssh.apache;version="6.6.0.qualifier";roots="." diff --git a/org.eclipse.jgit.ssh.apache/pom.xml b/org.eclipse.jgit.ssh.apache/pom.xml index 88557a91a5..8a4d6690a7 100644 --- a/org.eclipse.jgit.ssh.apache/pom.xml +++ b/org.eclipse.jgit.ssh.apache/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.ssh.apache</artifactId> diff --git a/org.eclipse.jgit.ssh.jsch.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.ssh.jsch.test/META-INF/MANIFEST.MF index 2e57de4dfe..4f288c4ed6 100644 --- a/org.eclipse.jgit.ssh.jsch.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.ssh.jsch.test/META-INF/MANIFEST.MF @@ -3,18 +3,18 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.ssh.jsch.test Bundle-SymbolicName: org.eclipse.jgit.ssh.jsch.test -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-11 Import-Package: com.jcraft.jsch;version="[0.1.54,0.2.0)", - org.eclipse.jgit.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.junit;version="[6.5.1,6.6.0)", - org.eclipse.jgit.junit.ssh;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.ssh.jsch;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)", + org.eclipse.jgit.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.junit;version="[6.6.0,6.7.0)", + org.eclipse.jgit.junit.ssh;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.ssh.jsch;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)", org.hamcrest;version="[1.1.0,3.0.0)", org.junit;version="[4.13,5.0.0)", org.junit.experimental.theories;version="[4.13,5.0.0)", diff --git a/org.eclipse.jgit.ssh.jsch.test/pom.xml b/org.eclipse.jgit.ssh.jsch.test/pom.xml index 158e967e44..c9ad00975d 100644 --- a/org.eclipse.jgit.ssh.jsch.test/pom.xml +++ b/org.eclipse.jgit.ssh.jsch.test/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.ssh.jsch.test</artifactId> diff --git a/org.eclipse.jgit.ssh.jsch/META-INF/MANIFEST.MF b/org.eclipse.jgit.ssh.jsch/META-INF/MANIFEST.MF index 61a4ee10f5..9b56078351 100644 --- a/org.eclipse.jgit.ssh.jsch/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.ssh.jsch/META-INF/MANIFEST.MF @@ -3,19 +3,19 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.ssh.jsch Bundle-SymbolicName: org.eclipse.jgit.ssh.jsch;singleton:=true -Fragment-Host: org.eclipse.jgit;bundle-version="[6.5.1,6.6.0)" +Fragment-Host: org.eclipse.jgit;bundle-version="[6.6.0,6.7.0)" Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-ActivationPolicy: lazy -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-RequiredExecutionEnvironment: JavaSE-11 -Export-Package: org.eclipse.jgit.transport.ssh.jsch;version="6.5.1" +Export-Package: org.eclipse.jgit.transport.ssh.jsch;version="6.6.0" Import-Package: com.jcraft.jsch;version="[0.1.37,0.2.0)", - org.eclipse.jgit.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.transport.ssh;version="[6.5.1,6.6.0)", - org.eclipse.jgit.nls;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util.io;version="[6.5.1,6.6.0)", + org.eclipse.jgit.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.transport.ssh;version="[6.6.0,6.7.0)", + org.eclipse.jgit.nls;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util.io;version="[6.6.0,6.7.0)", org.slf4j;version="[1.7.0,2.0.0)" diff --git a/org.eclipse.jgit.ssh.jsch/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.ssh.jsch/META-INF/SOURCE-MANIFEST.MF index f96290cf8f..bbdab6b4b4 100644 --- a/org.eclipse.jgit.ssh.jsch/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.ssh.jsch/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.ssh.jsch - Sources Bundle-SymbolicName: org.eclipse.jgit.ssh.jsch.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.5.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.ssh.jsch;version="6.5.1.qualifier";roots="." +Bundle-Version: 6.6.0.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.ssh.jsch;version="6.6.0.qualifier";roots="." diff --git a/org.eclipse.jgit.ssh.jsch/pom.xml b/org.eclipse.jgit.ssh.jsch/pom.xml index 9336ce130b..96653a7169 100644 --- a/org.eclipse.jgit.ssh.jsch/pom.xml +++ b/org.eclipse.jgit.ssh.jsch/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.ssh.jsch</artifactId> diff --git a/org.eclipse.jgit.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.test/META-INF/MANIFEST.MF index e2390b3e17..d4186343b1 100644 --- a/org.eclipse.jgit.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.test/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.test Bundle-SymbolicName: org.eclipse.jgit.test -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Localization: plugin Bundle-Vendor: %Bundle-Vendor Bundle-RequiredExecutionEnvironment: JavaSE-11 @@ -16,64 +16,64 @@ Import-Package: com.googlecode.javaewah;version="[1.1.6,2.0.0)", org.apache.commons.compress.compressors.gzip;version="[1.15.0,2.0)", org.apache.commons.compress.compressors.xz;version="[1.15.0,2.0)", org.assertj.core.api;version="[3.14.0,4.0.0)", - org.eclipse.jgit.annotations;version="[6.5.1,6.6.0)", - org.eclipse.jgit.api;version="[6.5.1,6.6.0)", - org.eclipse.jgit.api.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.archive;version="[6.5.1,6.6.0)", - org.eclipse.jgit.attributes;version="[6.5.1,6.6.0)", - org.eclipse.jgit.awtui;version="[6.5.1,6.6.0)", - org.eclipse.jgit.blame;version="[6.5.1,6.6.0)", - org.eclipse.jgit.diff;version="[6.5.1,6.6.0)", - org.eclipse.jgit.dircache;version="[6.5.1,6.6.0)", - org.eclipse.jgit.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.events;version="[6.5.1,6.6.0)", - org.eclipse.jgit.fnmatch;version="[6.5.1,6.6.0)", - org.eclipse.jgit.gitrepo;version="[6.5.1,6.6.0)", - org.eclipse.jgit.hooks;version="[6.5.1,6.6.0)", - org.eclipse.jgit.ignore;version="[6.5.1,6.6.0)", - org.eclipse.jgit.ignore.internal;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.diff;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.diffmergetool;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.fsck;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.revwalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.commitgraph;version="6.5.1", - org.eclipse.jgit.internal.storage.dfs;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.file;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.io;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.memory;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.pack;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.storage.reftable;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.transport.connectivity;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.transport.http;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.transport.parser;version="[6.5.1,6.6.0)", - org.eclipse.jgit.internal.transport.ssh;version="[6.5.1,6.6.0)", - org.eclipse.jgit.junit;version="[6.5.1,6.6.0)", - org.eclipse.jgit.junit.time;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lfs;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib.internal;version="[6.5.1,6.6.0)", - org.eclipse.jgit.logging;version="[6.5.1,6.6.0)", - org.eclipse.jgit.merge;version="[6.5.1,6.6.0)", - org.eclipse.jgit.nls;version="[6.5.1,6.6.0)", - org.eclipse.jgit.notes;version="[6.5.1,6.6.0)", - org.eclipse.jgit.patch;version="[6.5.1,6.6.0)", - org.eclipse.jgit.pgm;version="[6.5.1,6.6.0)", - org.eclipse.jgit.pgm.internal;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revplot;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revwalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revwalk.filter;version="[6.5.1,6.6.0)", - org.eclipse.jgit.storage.file;version="[6.5.1,6.6.0)", - org.eclipse.jgit.storage.pack;version="[6.5.1,6.6.0)", - org.eclipse.jgit.submodule;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.http;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport.resolver;version="[6.5.1,6.6.0)", - org.eclipse.jgit.treewalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.treewalk.filter;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util.io;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util.sha1;version="[6.5.1,6.6.0)", + org.eclipse.jgit.annotations;version="[6.6.0,6.7.0)", + org.eclipse.jgit.api;version="[6.6.0,6.7.0)", + org.eclipse.jgit.api.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.archive;version="[6.6.0,6.7.0)", + org.eclipse.jgit.attributes;version="[6.6.0,6.7.0)", + org.eclipse.jgit.awtui;version="[6.6.0,6.7.0)", + org.eclipse.jgit.blame;version="[6.6.0,6.7.0)", + org.eclipse.jgit.diff;version="[6.6.0,6.7.0)", + org.eclipse.jgit.dircache;version="[6.6.0,6.7.0)", + org.eclipse.jgit.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.events;version="[6.6.0,6.7.0)", + org.eclipse.jgit.fnmatch;version="[6.6.0,6.7.0)", + org.eclipse.jgit.gitrepo;version="[6.6.0,6.7.0)", + org.eclipse.jgit.hooks;version="[6.6.0,6.7.0)", + org.eclipse.jgit.ignore;version="[6.6.0,6.7.0)", + org.eclipse.jgit.ignore.internal;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.diff;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.diffmergetool;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.fsck;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.revwalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.commitgraph;version="6.6.0", + org.eclipse.jgit.internal.storage.dfs;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.file;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.io;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.memory;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.pack;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.storage.reftable;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.transport.connectivity;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.transport.http;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.transport.parser;version="[6.6.0,6.7.0)", + org.eclipse.jgit.internal.transport.ssh;version="[6.6.0,6.7.0)", + org.eclipse.jgit.junit;version="[6.6.0,6.7.0)", + org.eclipse.jgit.junit.time;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lfs;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib.internal;version="[6.6.0,6.7.0)", + org.eclipse.jgit.logging;version="[6.6.0,6.7.0)", + org.eclipse.jgit.merge;version="[6.6.0,6.7.0)", + org.eclipse.jgit.nls;version="[6.6.0,6.7.0)", + org.eclipse.jgit.notes;version="[6.6.0,6.7.0)", + org.eclipse.jgit.patch;version="[6.6.0,6.7.0)", + org.eclipse.jgit.pgm;version="[6.6.0,6.7.0)", + org.eclipse.jgit.pgm.internal;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revplot;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revwalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revwalk.filter;version="[6.6.0,6.7.0)", + org.eclipse.jgit.storage.file;version="[6.6.0,6.7.0)", + org.eclipse.jgit.storage.pack;version="[6.6.0,6.7.0)", + org.eclipse.jgit.submodule;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.http;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport.resolver;version="[6.6.0,6.7.0)", + org.eclipse.jgit.treewalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.treewalk.filter;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util.io;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util.sha1;version="[6.6.0,6.7.0)", org.hamcrest;version="[1.1.0,3.0.0)", org.hamcrest.collection;version="[1.1.0,3.0.0)", org.junit;version="[4.13,5.0.0)", diff --git a/org.eclipse.jgit.test/pom.xml b/org.eclipse.jgit.test/pom.xml index b7d932a408..81dec21642 100644 --- a/org.eclipse.jgit.test/pom.xml +++ b/org.eclipse.jgit.test/pom.xml @@ -19,7 +19,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.test</artifactId> diff --git a/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/conflict.patch b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/conflict.patch new file mode 100644 index 0000000000..547fcdae26 --- /dev/null +++ b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/conflict.patch @@ -0,0 +1,8 @@ +diff --git a/conflict b/conflict +index 2e65efe..7898192 100644 +--- a/conflict ++++ b/conflict +@@ -1 +1 @@ +-a different preimage line +\ No newline at end of file ++a new line diff --git a/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/conflict_PostImage b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/conflict_PostImage new file mode 100644 index 0000000000..fa27877b05 --- /dev/null +++ b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/conflict_PostImage @@ -0,0 +1 @@ +preimage line diff --git a/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/conflict_PreImage b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/conflict_PreImage new file mode 100644 index 0000000000..fa27877b05 --- /dev/null +++ b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/conflict_PreImage @@ -0,0 +1 @@ +preimage line diff --git a/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/z_e.patch b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/z_e.patch deleted file mode 100644 index f531033845..0000000000 --- a/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/z_e.patch +++ /dev/null @@ -1,297 +0,0 @@ -diff --git a/z_e b/z_e -index 8d8786f..7888356 100644 ---- a/z_e -+++ b/z_e -@@ -20,6 +20,7 @@ - package org.jsonschema2pojo.util; - - import java.util.ArrayList; -+import java.util.Collections; - import java.util.List; - import java.util.regex.Matcher; - import java.util.regex.Pattern; -@@ -36,76 +37,81 @@ - private static final Pattern UNDERSCORE_PATTERN_1 = Pattern.compile("([A-Z]+)([A-Z][a-z])"); - private static final Pattern UNDERSCORE_PATTERN_2 = Pattern.compile("([a-z\\d])([A-Z])"); - -- private List<RuleAndReplacement> plurals = new ArrayList<RuleAndReplacement>(); -- private List<RuleAndReplacement> singulars = new ArrayList<RuleAndReplacement>(); -- private List<String> uncountables = new ArrayList<String>(); -+ private final List<RuleAndReplacement> plurals; -+ private final List<RuleAndReplacement> singulars; -+ private final List<String> uncountables; - -- private static Inflector instance = new Inflector(); -+ private static Inflector instance = createDefaultBuilder().build(); - -- private Inflector() { -- // Woo, you can't touch me. -- -- initialize(); -+ private Inflector(Builder builder) { -+ plurals = Collections.unmodifiableList(builder.plurals); -+ singulars = Collections.unmodifiableList(builder.singulars); -+ uncountables = Collections.unmodifiableList(builder.uncountables); - } - -- private void initialize() { -- plural("$", "s"); -- plural("s$", "s"); -- plural("(ax|test)is$", "$1es"); -- plural("(octop|vir)us$", "$1i"); -- plural("(alias|status)$", "$1es"); -- plural("(bu)s$", "$1es"); -- plural("(buffal|tomat)o$", "$1oes"); -- plural("([ti])um$", "$1a"); -- plural("sis$", "ses"); -- plural("(?:([^f])fe|([lr])f)$", "$1$2ves"); -- plural("(hive)$", "$1s"); -- plural("([^aeiouy]|qu)y$", "$1ies"); -- plural("([^aeiouy]|qu)ies$", "$1y"); -- plural("(x|ch|ss|sh)$", "$1es"); -- plural("(matr|vert|ind)ix|ex$", "$1ices"); -- plural("([m|l])ouse$", "$1ice"); -- plural("(ox)$", "$1en"); -- plural("(quiz)$", "$1zes"); -+ public static Inflector.Builder createDefaultBuilder() -+ { -+ Builder builder = builder(); - -- singular("s$", ""); -- singular("(n)ews$", "$1ews"); -- singular("([ti])a$", "$1um"); -- singular("((a)naly|(b)a|(d)iagno|(p)arenthe|(p)rogno|(s)ynop|(t)he)ses$", "$1$2sis"); -- singular("(^analy)ses$", "$1sis"); -- singular("([^f])ves$", "$1fe"); -- singular("(hive)s$", "$1"); -- singular("(tive)s$", "$1"); -- singular("([lr])ves$", "$1f"); -- singular("([^aeiouy]|qu)ies$", "$1y"); -- singular("(s)eries$", "$1eries"); -- singular("(m)ovies$", "$1ovie"); -- singular("(x|ch|ss|sh)es$", "$1"); -- singular("([m|l])ice$", "$1ouse"); -- singular("(bus)es$", "$1"); -- singular("(o)es$", "$1"); -- singular("(shoe)s$", "$1"); -- singular("(cris|ax|test)es$", "$1is"); -- singular("([octop|vir])i$", "$1us"); -- singular("(alias|status)es$", "$1"); -- singular("^(ox)en", "$1"); -- singular("(vert|ind)ices$", "$1ex"); -- singular("(matr)ices$", "$1ix"); -- singular("(quiz)zes$", "$1"); -- singular("(ess)$", "$1"); -+ builder.plural("$", "s") -+ .plural("s$", "s") -+ .plural("(ax|test)is$", "$1es") -+ .plural("(octop|vir)us$", "$1i") -+ .plural("(alias|status)$", "$1es") -+ .plural("(bu)s$", "$1es") -+ .plural("(buffal|tomat)o$", "$1oes") -+ .plural("([ti])um$", "$1a") -+ .plural("sis$", "ses") -+ .plural("(?:([^f])fe|([lr])f)$", "$1$2ves") -+ .plural("(hive)$", "$1s") -+ .plural("([^aeiouy]|qu)y$", "$1ies") -+ .plural("([^aeiouy]|qu)ies$", "$1y") -+ .plural("(x|ch|ss|sh)$", "$1es") -+ .plural("(matr|vert|ind)ix|ex$", "$1ices") -+ .plural("([m|l])ouse$", "$1ice") -+ .plural("(ox)$", "$1en") -+ .plural("(quiz)$", "$1zes"); - -- singular("men$", "man"); -- plural("man$", "men"); -+ builder.singular("s$", "") -+ .singular("(n)ews$", "$1ews") -+ .singular("([ti])a$", "$1um") -+ .singular("((a)naly|(b)a|(d)iagno|(p)arenthe|(p)rogno|(s)ynop|(t)he)ses$", "$1$2sis") -+ .singular("(^analy)ses$", "$1sis") -+ .singular("([^f])ves$", "$1fe") -+ .singular("(hive)s$", "$1") -+ .singular("(tive)s$", "$1") -+ .singular("([lr])ves$", "$1f") -+ .singular("([^aeiouy]|qu)ies$", "$1y") -+ .singular("(s)eries$", "$1eries") -+ .singular("(m)ovies$", "$1ovie") -+ .singular("(x|ch|ss|sh)es$", "$1") -+ .singular("([m|l])ice$", "$1ouse") -+ .singular("(bus)es$", "$1") -+ .singular("(o)es$", "$1") -+ .singular("(shoe)s$", "$1") -+ .singular("(cris|ax|test)es$", "$1is") -+ .singular("([octop|vir])i$", "$1us") -+ .singular("(alias|status)es$", "$1") -+ .singular("^(ox)en", "$1") -+ .singular("(vert|ind)ices$", "$1ex") -+ .singular("(matr)ices$", "$1ix") -+ .singular("(quiz)zes$", "$1") -+ .singular("(ess)$", "$1"); - -- irregular("curve", "curves"); -- irregular("leaf", "leaves"); -- irregular("roof", "rooves"); -- irregular("person", "people"); -- irregular("child", "children"); -- irregular("sex", "sexes"); -- irregular("move", "moves"); -+ builder.singular("men$", "man") -+ .plural("man$", "men"); - -- uncountable(new String[] { "equipment", "information", "rice", "money", "species", "series", "fish", "sheep", "s" }); -+ builder.irregular("curve", "curves") -+ .irregular("leaf", "leaves") -+ .irregular("roof", "rooves") -+ .irregular("person", "people") -+ .irregular("child", "children") -+ .irregular("sex", "sexes") -+ .irregular("move", "moves"); -+ -+ builder.uncountable(new String[] { "equipment", "information", "rice", "money", "species", "series", "fish", "sheep", "s" }); -+ -+ return builder; - } - - public static Inflector getInstance() { -@@ -122,28 +128,27 @@ - return underscoredWord; - } - -- public synchronized String pluralize(String word) { -+ public String pluralize(String word) { - if (uncountables.contains(word.toLowerCase())) { - return word; - } - return replaceWithFirstRule(word, plurals); - } - -- public synchronized String singularize(String word) { -+ public String singularize(String word) { - if (uncountables.contains(word.toLowerCase())) { - return word; - } - return replaceWithFirstRule(word, singulars); - } - -- private String replaceWithFirstRule(String word, List<RuleAndReplacement> ruleAndReplacements) { -+ private static String replaceWithFirstRule(String word, List<RuleAndReplacement> ruleAndReplacements) { - - for (RuleAndReplacement rar : ruleAndReplacements) { -- String rule = rar.getRule(); - String replacement = rar.getReplacement(); - - // Return if we find a match. -- Matcher matcher = Pattern.compile(rule, Pattern.CASE_INSENSITIVE).matcher(word); -+ Matcher matcher = rar.getPattern().matcher(word); - if (matcher.find()) { - return matcher.replaceAll(replacement); - } -@@ -161,49 +166,68 @@ - return tableize(className); - } - -- private void plural(String rule, String replacement) { -- plurals.add(0, new RuleAndReplacement(rule, replacement)); -+ public static Builder builder() -+ { -+ return new Builder(); - } - -- private void singular(String rule, String replacement) { -- singulars.add(0, new RuleAndReplacement(rule, replacement)); -+ // Ugh, no open structs in Java (not-natively at least). -+ private static class RuleAndReplacement { -+ private final String rule; -+ private final String replacement; -+ private final Pattern pattern; -+ -+ public RuleAndReplacement(String rule, String replacement) { -+ this.rule = rule; -+ this.replacement = replacement; -+ this.pattern = Pattern.compile(rule, Pattern.CASE_INSENSITIVE); -+ } -+ -+ public String getReplacement() { -+ return replacement; -+ } -+ -+ public String getRule() { -+ return rule; -+ } -+ -+ public Pattern getPattern() { -+ return pattern; -+ } - } - -- private void irregular(String singular, String plural) { -- plural(singular, plural); -- singular(plural, singular); -- } -+ public static class Builder -+ { -+ private List<RuleAndReplacement> plurals = new ArrayList<RuleAndReplacement>(); -+ private List<RuleAndReplacement> singulars = new ArrayList<RuleAndReplacement>(); -+ private List<String> uncountables = new ArrayList<String>(); - -- private void uncountable(String... words) { -- for (String word : words) { -- uncountables.add(word); -+ public Builder plural(String rule, String replacement) { -+ plurals.add(0, new RuleAndReplacement(rule, replacement)); -+ return this; -+ } -+ -+ public Builder singular(String rule, String replacement) { -+ singulars.add(0, new RuleAndReplacement(rule, replacement)); -+ return this; -+ } -+ -+ public Builder irregular(String singular, String plural) { -+ plural(singular, plural); -+ singular(plural, singular); -+ return this; -+ } -+ -+ public Builder uncountable(String... words) { -+ for (String word : words) { -+ uncountables.add(word); -+ } -+ return this; -+ } -+ -+ public Inflector build() -+ { -+ return new Inflector(this); - } - } - } -- --// Ugh, no open structs in Java (not-natively at least). --class RuleAndReplacement { -- private String rule; -- private String replacement; -- -- public RuleAndReplacement(String rule, String replacement) { -- this.rule = rule; -- this.replacement = replacement; -- } -- -- public String getReplacement() { -- return replacement; -- } -- -- public void setReplacement(String replacement) { -- this.replacement = replacement; -- } -- -- public String getRule() { -- return rule; -- } -- -- public void setRule(String rule) { -- this.rule = rule; -- } --} -\ No newline at end of file diff --git a/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/z_e_PostImage b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/z_e_PostImage deleted file mode 100644 index 7888356948..0000000000 --- a/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/z_e_PostImage +++ /dev/null @@ -1,233 +0,0 @@ -/** - * Copyright © 2007 Chu Yeow Cheah - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * Copied verbatim from http://dzone.com/snippets/java-inflections, used - * and licensed with express permission from the author Chu Yeow Cheah. - */ - -package org.jsonschema2pojo.util; - -import java.util.ArrayList; -import java.util.Collections; -import java.util.List; -import java.util.regex.Matcher; -import java.util.regex.Pattern; - -/** - * Transforms words (from singular to plural, from camelCase to under_score, - * etc.). I got bored of doing Real Work... - * - * @author chuyeow - */ -public class Inflector { - - // Pfft, can't think of a better name, but this is needed to avoid the price of initializing the pattern on each call. - private static final Pattern UNDERSCORE_PATTERN_1 = Pattern.compile("([A-Z]+)([A-Z][a-z])"); - private static final Pattern UNDERSCORE_PATTERN_2 = Pattern.compile("([a-z\\d])([A-Z])"); - - private final List<RuleAndReplacement> plurals; - private final List<RuleAndReplacement> singulars; - private final List<String> uncountables; - - private static Inflector instance = createDefaultBuilder().build(); - - private Inflector(Builder builder) { - plurals = Collections.unmodifiableList(builder.plurals); - singulars = Collections.unmodifiableList(builder.singulars); - uncountables = Collections.unmodifiableList(builder.uncountables); - } - - public static Inflector.Builder createDefaultBuilder() - { - Builder builder = builder(); - - builder.plural("$", "s") - .plural("s$", "s") - .plural("(ax|test)is$", "$1es") - .plural("(octop|vir)us$", "$1i") - .plural("(alias|status)$", "$1es") - .plural("(bu)s$", "$1es") - .plural("(buffal|tomat)o$", "$1oes") - .plural("([ti])um$", "$1a") - .plural("sis$", "ses") - .plural("(?:([^f])fe|([lr])f)$", "$1$2ves") - .plural("(hive)$", "$1s") - .plural("([^aeiouy]|qu)y$", "$1ies") - .plural("([^aeiouy]|qu)ies$", "$1y") - .plural("(x|ch|ss|sh)$", "$1es") - .plural("(matr|vert|ind)ix|ex$", "$1ices") - .plural("([m|l])ouse$", "$1ice") - .plural("(ox)$", "$1en") - .plural("(quiz)$", "$1zes"); - - builder.singular("s$", "") - .singular("(n)ews$", "$1ews") - .singular("([ti])a$", "$1um") - .singular("((a)naly|(b)a|(d)iagno|(p)arenthe|(p)rogno|(s)ynop|(t)he)ses$", "$1$2sis") - .singular("(^analy)ses$", "$1sis") - .singular("([^f])ves$", "$1fe") - .singular("(hive)s$", "$1") - .singular("(tive)s$", "$1") - .singular("([lr])ves$", "$1f") - .singular("([^aeiouy]|qu)ies$", "$1y") - .singular("(s)eries$", "$1eries") - .singular("(m)ovies$", "$1ovie") - .singular("(x|ch|ss|sh)es$", "$1") - .singular("([m|l])ice$", "$1ouse") - .singular("(bus)es$", "$1") - .singular("(o)es$", "$1") - .singular("(shoe)s$", "$1") - .singular("(cris|ax|test)es$", "$1is") - .singular("([octop|vir])i$", "$1us") - .singular("(alias|status)es$", "$1") - .singular("^(ox)en", "$1") - .singular("(vert|ind)ices$", "$1ex") - .singular("(matr)ices$", "$1ix") - .singular("(quiz)zes$", "$1") - .singular("(ess)$", "$1"); - - builder.singular("men$", "man") - .plural("man$", "men"); - - builder.irregular("curve", "curves") - .irregular("leaf", "leaves") - .irregular("roof", "rooves") - .irregular("person", "people") - .irregular("child", "children") - .irregular("sex", "sexes") - .irregular("move", "moves"); - - builder.uncountable(new String[] { "equipment", "information", "rice", "money", "species", "series", "fish", "sheep", "s" }); - - return builder; - } - - public static Inflector getInstance() { - return instance; - } - - private String underscore(String camelCasedWord) { - - // Regexes in Java are fucking stupid... - String underscoredWord = UNDERSCORE_PATTERN_1.matcher(camelCasedWord).replaceAll("$1_$2"); - underscoredWord = UNDERSCORE_PATTERN_2.matcher(underscoredWord).replaceAll("$1_$2"); - underscoredWord = underscoredWord.replace('-', '_').toLowerCase(); - - return underscoredWord; - } - - public String pluralize(String word) { - if (uncountables.contains(word.toLowerCase())) { - return word; - } - return replaceWithFirstRule(word, plurals); - } - - public String singularize(String word) { - if (uncountables.contains(word.toLowerCase())) { - return word; - } - return replaceWithFirstRule(word, singulars); - } - - private static String replaceWithFirstRule(String word, List<RuleAndReplacement> ruleAndReplacements) { - - for (RuleAndReplacement rar : ruleAndReplacements) { - String replacement = rar.getReplacement(); - - // Return if we find a match. - Matcher matcher = rar.getPattern().matcher(word); - if (matcher.find()) { - return matcher.replaceAll(replacement); - } - } - return word; - } - - private String tableize(String className) { - return pluralize(underscore(className)); - } - - private String tableize(Class<?> klass) { - // Strip away package name - we only want the 'base' class name. - String className = klass.getName().replace(klass.getPackage().getName() + ".", ""); - return tableize(className); - } - - public static Builder builder() - { - return new Builder(); - } - - // Ugh, no open structs in Java (not-natively at least). - private static class RuleAndReplacement { - private final String rule; - private final String replacement; - private final Pattern pattern; - - public RuleAndReplacement(String rule, String replacement) { - this.rule = rule; - this.replacement = replacement; - this.pattern = Pattern.compile(rule, Pattern.CASE_INSENSITIVE); - } - - public String getReplacement() { - return replacement; - } - - public String getRule() { - return rule; - } - - public Pattern getPattern() { - return pattern; - } - } - - public static class Builder - { - private List<RuleAndReplacement> plurals = new ArrayList<RuleAndReplacement>(); - private List<RuleAndReplacement> singulars = new ArrayList<RuleAndReplacement>(); - private List<String> uncountables = new ArrayList<String>(); - - public Builder plural(String rule, String replacement) { - plurals.add(0, new RuleAndReplacement(rule, replacement)); - return this; - } - - public Builder singular(String rule, String replacement) { - singulars.add(0, new RuleAndReplacement(rule, replacement)); - return this; - } - - public Builder irregular(String singular, String plural) { - plural(singular, plural); - singular(plural, singular); - return this; - } - - public Builder uncountable(String... words) { - for (String word : words) { - uncountables.add(word); - } - return this; - } - - public Inflector build() - { - return new Inflector(this); - } - } -} diff --git a/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/z_e_PreImage b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/z_e_PreImage deleted file mode 100644 index 8d8786f58c..0000000000 --- a/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/z_e_PreImage +++ /dev/null @@ -1,209 +0,0 @@ -/** - * Copyright © 2007 Chu Yeow Cheah - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * Copied verbatim from http://dzone.com/snippets/java-inflections, used - * and licensed with express permission from the author Chu Yeow Cheah. - */ - -package org.jsonschema2pojo.util; - -import java.util.ArrayList; -import java.util.List; -import java.util.regex.Matcher; -import java.util.regex.Pattern; - -/** - * Transforms words (from singular to plural, from camelCase to under_score, - * etc.). I got bored of doing Real Work... - * - * @author chuyeow - */ -public class Inflector { - - // Pfft, can't think of a better name, but this is needed to avoid the price of initializing the pattern on each call. - private static final Pattern UNDERSCORE_PATTERN_1 = Pattern.compile("([A-Z]+)([A-Z][a-z])"); - private static final Pattern UNDERSCORE_PATTERN_2 = Pattern.compile("([a-z\\d])([A-Z])"); - - private List<RuleAndReplacement> plurals = new ArrayList<RuleAndReplacement>(); - private List<RuleAndReplacement> singulars = new ArrayList<RuleAndReplacement>(); - private List<String> uncountables = new ArrayList<String>(); - - private static Inflector instance = new Inflector(); - - private Inflector() { - // Woo, you can't touch me. - - initialize(); - } - - private void initialize() { - plural("$", "s"); - plural("s$", "s"); - plural("(ax|test)is$", "$1es"); - plural("(octop|vir)us$", "$1i"); - plural("(alias|status)$", "$1es"); - plural("(bu)s$", "$1es"); - plural("(buffal|tomat)o$", "$1oes"); - plural("([ti])um$", "$1a"); - plural("sis$", "ses"); - plural("(?:([^f])fe|([lr])f)$", "$1$2ves"); - plural("(hive)$", "$1s"); - plural("([^aeiouy]|qu)y$", "$1ies"); - plural("([^aeiouy]|qu)ies$", "$1y"); - plural("(x|ch|ss|sh)$", "$1es"); - plural("(matr|vert|ind)ix|ex$", "$1ices"); - plural("([m|l])ouse$", "$1ice"); - plural("(ox)$", "$1en"); - plural("(quiz)$", "$1zes"); - - singular("s$", ""); - singular("(n)ews$", "$1ews"); - singular("([ti])a$", "$1um"); - singular("((a)naly|(b)a|(d)iagno|(p)arenthe|(p)rogno|(s)ynop|(t)he)ses$", "$1$2sis"); - singular("(^analy)ses$", "$1sis"); - singular("([^f])ves$", "$1fe"); - singular("(hive)s$", "$1"); - singular("(tive)s$", "$1"); - singular("([lr])ves$", "$1f"); - singular("([^aeiouy]|qu)ies$", "$1y"); - singular("(s)eries$", "$1eries"); - singular("(m)ovies$", "$1ovie"); - singular("(x|ch|ss|sh)es$", "$1"); - singular("([m|l])ice$", "$1ouse"); - singular("(bus)es$", "$1"); - singular("(o)es$", "$1"); - singular("(shoe)s$", "$1"); - singular("(cris|ax|test)es$", "$1is"); - singular("([octop|vir])i$", "$1us"); - singular("(alias|status)es$", "$1"); - singular("^(ox)en", "$1"); - singular("(vert|ind)ices$", "$1ex"); - singular("(matr)ices$", "$1ix"); - singular("(quiz)zes$", "$1"); - singular("(ess)$", "$1"); - - singular("men$", "man"); - plural("man$", "men"); - - irregular("curve", "curves"); - irregular("leaf", "leaves"); - irregular("roof", "rooves"); - irregular("person", "people"); - irregular("child", "children"); - irregular("sex", "sexes"); - irregular("move", "moves"); - - uncountable(new String[] { "equipment", "information", "rice", "money", "species", "series", "fish", "sheep", "s" }); - } - - public static Inflector getInstance() { - return instance; - } - - private String underscore(String camelCasedWord) { - - // Regexes in Java are fucking stupid... - String underscoredWord = UNDERSCORE_PATTERN_1.matcher(camelCasedWord).replaceAll("$1_$2"); - underscoredWord = UNDERSCORE_PATTERN_2.matcher(underscoredWord).replaceAll("$1_$2"); - underscoredWord = underscoredWord.replace('-', '_').toLowerCase(); - - return underscoredWord; - } - - public synchronized String pluralize(String word) { - if (uncountables.contains(word.toLowerCase())) { - return word; - } - return replaceWithFirstRule(word, plurals); - } - - public synchronized String singularize(String word) { - if (uncountables.contains(word.toLowerCase())) { - return word; - } - return replaceWithFirstRule(word, singulars); - } - - private String replaceWithFirstRule(String word, List<RuleAndReplacement> ruleAndReplacements) { - - for (RuleAndReplacement rar : ruleAndReplacements) { - String rule = rar.getRule(); - String replacement = rar.getReplacement(); - - // Return if we find a match. - Matcher matcher = Pattern.compile(rule, Pattern.CASE_INSENSITIVE).matcher(word); - if (matcher.find()) { - return matcher.replaceAll(replacement); - } - } - return word; - } - - private String tableize(String className) { - return pluralize(underscore(className)); - } - - private String tableize(Class<?> klass) { - // Strip away package name - we only want the 'base' class name. - String className = klass.getName().replace(klass.getPackage().getName() + ".", ""); - return tableize(className); - } - - private void plural(String rule, String replacement) { - plurals.add(0, new RuleAndReplacement(rule, replacement)); - } - - private void singular(String rule, String replacement) { - singulars.add(0, new RuleAndReplacement(rule, replacement)); - } - - private void irregular(String singular, String plural) { - plural(singular, plural); - singular(plural, singular); - } - - private void uncountable(String... words) { - for (String word : words) { - uncountables.add(word); - } - } -} - -// Ugh, no open structs in Java (not-natively at least). -class RuleAndReplacement { - private String rule; - private String replacement; - - public RuleAndReplacement(String rule, String replacement) { - this.rule = rule; - this.replacement = replacement; - } - - public String getReplacement() { - return replacement; - } - - public void setReplacement(String replacement) { - this.replacement = replacement; - } - - public String getRule() { - return rule; - } - - public void setRule(String rule) { - this.rule = rule; - } -}
\ No newline at end of file diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/TagCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/TagCommandTest.java index 99034174ba..c3f72135d6 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/TagCommandTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/TagCommandTest.java @@ -17,13 +17,16 @@ import static org.junit.Assert.assertTrue; import static org.junit.Assert.fail; import java.io.IOException; +import java.util.Arrays; import java.util.List; +import java.util.stream.Collectors; import org.eclipse.jgit.api.errors.GitAPIException; import org.eclipse.jgit.api.errors.InvalidTagNameException; import org.eclipse.jgit.api.errors.JGitInternalException; import org.eclipse.jgit.api.errors.RefAlreadyExistsException; import org.eclipse.jgit.junit.RepositoryTestCase; +import org.eclipse.jgit.junit.TestRepository; import org.eclipse.jgit.lib.Ref; import org.eclipse.jgit.lib.RefUpdate; import org.eclipse.jgit.lib.Repository; @@ -286,4 +289,45 @@ public class TagCommandTest extends RepositoryTestCase { } } + @Test + public void testListTagsContainingCommit() throws Exception { + /* c3 + * | + * v2 - c2 b2 - v1 + * | | + * c1 b1 + * \ / + * a + */ + try (TestRepository<Repository> r = new TestRepository<>( + db)) { + Git git = Git.wrap(db); + RevCommit a = r.commit().create(); + RevCommit b1 = r.commit(a); + RevCommit b2 = r.commit(b1); + RevCommit c1 = r.commit(a); + RevCommit c2 = r.commit(c1); + RevCommit c3 = r.commit(c2); + r.update("refs/tags/v1", r.tag("v1", b2)); + r.update("refs/tags/v2", r.tag("v1.1", c2)); + List<Ref> res = git.tagList().setContains(a).call(); + assertEquals(2, res.size()); + assertTrue(res.stream().map(Ref::getName) + .collect(Collectors.toSet()).containsAll( + Arrays.asList("refs/tags/v1", "refs/tags/v2"))); + + res = git.tagList().setContains(b1).call(); + assertEquals(1, res.size()); + assertTrue(res.stream().map(Ref::getName) + .collect(Collectors.toSet()).contains("refs/tags/v1")); + + res = git.tagList().setContains(c1).call(); + assertEquals(1, res.size()); + assertTrue(res.stream().map(Ref::getName) + .collect(Collectors.toSet()).contains("refs/tags/v2")); + + res = git.tagList().setContains(c3).call(); + assertEquals(0, res.size()); + } + } } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RefDirectoryTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RefDirectoryTest.java index 4b80f18970..619e585a90 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RefDirectoryTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RefDirectoryTest.java @@ -58,13 +58,13 @@ import org.junit.Test; public class RefDirectoryTest extends LocalDiskRepositoryTestCase { private Repository diskRepo; - private TestRepository<Repository> repo; + TestRepository<Repository> repo; - private RefDirectory refdir; + RefDirectory refdir; - private RevCommit A; + RevCommit A; - private RevCommit B; + RevCommit B; private RevTag v1_0; @@ -555,10 +555,6 @@ public class RefDirectoryTest extends LocalDiskRepositoryTestCase { @Test public void testGetRefs_LooseSorting_Bug_348834() throws IOException { Map<String, Ref> refs; - - writeLooseRef("refs/heads/my/a+b", A); - writeLooseRef("refs/heads/my/a/b/c", B); - final int[] count = new int[1]; ListenerHandle listener = Repository.getGlobalListenerList() @@ -566,14 +562,27 @@ public class RefDirectoryTest extends LocalDiskRepositoryTestCase { count[0]++; }); + // RefsChangedEvent on the first attempt to read a ref is not expected + // to be triggered (See Iea3a5035b0a1410b80b09cf53387b22b78b18018), so + // create an update and fire pending events to ensure subsequent events + // are fired. + writeLooseRef("refs/heads/test", A); refs = refdir.getRefs(RefDatabase.ALL); + count[0] = 0; + int origSize = refs.size(); + + writeLooseRef("refs/heads/my/a+b", A); + writeLooseRef("refs/heads/my/a/b/c", B); + refs = refdir.getRefs(RefDatabase.ALL); - listener.remove(); - assertEquals(1, count[0]); // Bug 348834 multiple RefsChangedEvents - assertEquals(2, refs.size()); + assertEquals(1, count[0]); + assertEquals(2, refs.size() - origSize); assertEquals(A, refs.get("refs/heads/my/a+b").getObjectId()); assertEquals(B, refs.get("refs/heads/my/a/b/c").getObjectId()); + refs = refdir.getRefs(RefDatabase.ALL); + assertEquals(1, count[0]); // Bug 348834 multiple RefsChangedEvents + listener.remove(); } @Test @@ -1340,25 +1349,25 @@ public class RefDirectoryTest extends LocalDiskRepositoryTestCase { assertEquals(Storage.LOOSE, ref.getStorage()); } - private void writeLooseRef(String name, AnyObjectId id) throws IOException { - writeLooseRef(name, id.name() + "\n"); - } - - private void writeLooseRef(String name, String content) throws IOException { - write(new File(diskRepo.getDirectory(), name), content); - } - - private void writePackedRef(String name, AnyObjectId id) throws IOException { + void writePackedRef(String name, AnyObjectId id) throws IOException { writePackedRefs(id.name() + " " + name + "\n"); } - private void writePackedRefs(String content) throws IOException { + void writePackedRefs(String content) throws IOException { File pr = new File(diskRepo.getDirectory(), "packed-refs"); write(pr, content); FS fs = diskRepo.getFS(); fs.setLastModified(pr.toPath(), Instant.now().minusSeconds(3600)); } + private void writeLooseRef(String name, AnyObjectId id) throws IOException { + writeLooseRef(name, id.name() + "\n"); + } + + private void writeLooseRef(String name, String content) throws IOException { + write(new File(diskRepo.getDirectory(), name), content); + } + private void deleteLooseRef(String name) { File path = new File(diskRepo.getDirectory(), name); assertTrue("deleted " + name, path.delete()); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/SnapshottingRefDirectoryTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/SnapshottingRefDirectoryTest.java new file mode 100644 index 0000000000..c3dafe4aa2 --- /dev/null +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/SnapshottingRefDirectoryTest.java @@ -0,0 +1,88 @@ +/* + * Copyright (c) 2023 Qualcomm Innovation Center, Inc. + * and other copyright owners as documented in the project's IP log. + * + * This program and the accompanying materials are made available under the + * terms of the Eclipse Distribution License v. 1.0 which is available at + * https://www.eclipse.org/org/documents/edl-v10.php. + * + * SPDX-License-Identifier: BSD-3-Clause + */ + +package org.eclipse.jgit.internal.storage.file; + +import org.eclipse.jgit.lib.NullProgressMonitor; +import org.eclipse.jgit.transport.ReceiveCommand; +import org.junit.Before; +import org.junit.Test; + +import java.io.IOException; + +import static org.junit.Assert.assertEquals; + +public class SnapshottingRefDirectoryTest extends RefDirectoryTest { + private RefDirectory originalRefDirectory; + + /** {@inheritDoc} */ + @Before + @Override + public void setUp() throws Exception { + super.setUp(); + originalRefDirectory = refdir; + refdir = refdir.createSnapshottingRefDirectory(); + } + + @Test + public void testSnapshot_CannotSeeExternalPackedRefsUpdates() + throws IOException { + String refName = "refs/heads/new"; + + writePackedRef(refName, A); + assertEquals(A, originalRefDirectory.exactRef(refName).getObjectId()); + assertEquals(A, refdir.exactRef(refName).getObjectId()); + + writePackedRef(refName, B); + assertEquals(B, originalRefDirectory.exactRef(refName).getObjectId()); + assertEquals(A, refdir.exactRef(refName).getObjectId()); + } + + @Test + public void testSnapshot_WriteThrough() throws IOException { + String refName = "refs/heads/new"; + + writePackedRef(refName, A); + assertEquals(A, originalRefDirectory.exactRef(refName).getObjectId()); + assertEquals(A, refdir.exactRef(refName).getObjectId()); + + PackedBatchRefUpdate update = refdir.newBatchUpdate(); + update.addCommand(new ReceiveCommand(A, B, refName)); + update.execute(repo.getRevWalk(), NullProgressMonitor.INSTANCE); + + assertEquals(B, originalRefDirectory.exactRef(refName).getObjectId()); + assertEquals(B, refdir.exactRef(refName).getObjectId()); + } + + @Test + public void testSnapshot_IncludeExternalPackedRefsUpdatesWithWrites() + throws IOException { + String refA = "refs/heads/refA"; + String refB = "refs/heads/refB"; + writePackedRefs("" + // + A.name() + " " + refA + "\n" + // + A.name() + " " + refB + "\n"); + assertEquals(A, refdir.exactRef(refA).getObjectId()); + assertEquals(A, refdir.exactRef(refB).getObjectId()); + + writePackedRefs("" + // + B.name() + " " + refA + "\n" + // + A.name() + " " + refB + "\n"); + PackedBatchRefUpdate update = refdir.newBatchUpdate(); + update.addCommand(new ReceiveCommand(A, B, refB)); + update.execute(repo.getRevWalk(), NullProgressMonitor.INSTANCE); + + assertEquals(B, originalRefDirectory.exactRef(refA).getObjectId()); + assertEquals(B, refdir.exactRef(refA).getObjectId()); + assertEquals(B, originalRefDirectory.exactRef(refB).getObjectId()); + assertEquals(B, refdir.exactRef(refB).getObjectId()); + } +} diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/patch/PatchApplierTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/patch/PatchApplierTest.java index 893fd61556..e2637257c5 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/patch/PatchApplierTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/patch/PatchApplierTest.java @@ -26,8 +26,6 @@ import java.nio.charset.StandardCharsets; import java.nio.file.Files; import org.eclipse.jgit.annotations.Nullable; import org.eclipse.jgit.api.Git; -import org.eclipse.jgit.api.errors.PatchApplyException; -import org.eclipse.jgit.api.errors.PatchFormatException; import org.eclipse.jgit.attributes.FilterCommand; import org.eclipse.jgit.attributes.FilterCommandFactory; import org.eclipse.jgit.attributes.FilterCommandRegistry; @@ -95,12 +93,16 @@ public class PatchApplierTest { } protected void initPreImage(String aName) throws Exception { - File f = new File(db.getWorkTree(), aName); preImage = IO .readWholeStream(getTestResource(aName + "_PreImage"), 0) .array(); + addFile(aName, preImage); + } + + protected void addFile(String aName, byte[] b) throws Exception { + File f = new File(db.getWorkTree(), aName); + Files.write(f.toPath(), b); try (Git git = new Git(db)) { - Files.write(f.toPath(), preImage); git.add().addFilepattern(aName).call(); } } @@ -112,15 +114,17 @@ public class PatchApplierTest { return new String(postImage, StandardCharsets.UTF_8); } - protected Result applyPatch() - throws PatchApplyException, PatchFormatException, IOException { - InputStream patchStream = getTestResource(name + ".patch"); - if (inCore) { - try (ObjectInserter oi = db.newObjectInserter()) { - return new PatchApplier(db, baseTip, oi).applyPatch(patchStream); + protected Result applyPatch() throws IOException { + try (InputStream patchStream = getTestResource(name + ".patch")) { + Patch patch = new Patch(); + patch.parse(patchStream); + if (inCore) { + try (ObjectInserter oi = db.newObjectInserter()) { + return new PatchApplier(db, baseTip, oi).applyPatch(patch); + } } + return new PatchApplier(db).applyPatch(patch); } - return new PatchApplier(db).applyPatch(patchStream); } protected static InputStream getTestResource(String patchFile) { @@ -159,6 +163,7 @@ public class PatchApplierTest { void verifyChange(Result result, String aName, boolean exists) throws Exception { + assertEquals(0, result.getErrors().size()); assertEquals(1, result.getPaths().size()); verifyContent(result, aName, exists); } @@ -181,6 +186,7 @@ public class PatchApplierTest { protected void checkBinary(Result result, int numberOfFiles) throws Exception { + assertEquals(0, result.getErrors().size()); assertEquals(numberOfFiles, result.getPaths().size()); if (inCore) { assertArrayEquals(postImage, @@ -371,6 +377,68 @@ public class PatchApplierTest { } @Test + public void testAddAlreadyExistingFile() throws Exception { + addFile("M1", "existing content".getBytes(StandardCharsets.UTF_8)); + init("M1", false, false); + + Result result = applyPatch(); + + assertEquals(1, result.getErrors().size()); + assertEquals(0, result.getPaths().size()); + } + + @Test + public void testDeleteNonexistentFile() throws Exception { + init("NonASCIIDel", false, false); + + Result result = applyPatch(); + + assertEquals(1, result.getErrors().size()); + assertEquals(0, result.getPaths().size()); + } + + @Test + public void testModifyNonexistentFile() throws Exception { + init("ShiftDown", false, true); + + Result result = applyPatch(); + + assertEquals(1, result.getErrors().size()); + assertEquals(0, result.getPaths().size()); + } + + @Test + public void testRenameNonexistentFile() throws Exception { + init("RenameNoHunks", false, true); + + Result result = applyPatch(); + + assertEquals(1, result.getErrors().size()); + assertEquals(0, result.getPaths().size()); + } + + @Test + public void testCopyNonexistentFile() throws Exception { + init("CopyWithHunks", false, true); + + Result result = applyPatch(); + + assertEquals(1, result.getErrors().size()); + assertEquals(0, result.getPaths().size()); + } + + @Test + public void testCopyOnTopAlreadyExistingFile() throws Exception { + addFile("CopyResult", "existing content".getBytes(StandardCharsets.UTF_8)); + init("CopyWithHunks", true, false); + + Result result = applyPatch(); + + assertEquals(1, result.getErrors().size()); + assertEquals(0, result.getPaths().size()); + } + + @Test public void testDoesNotAffectUnrelatedFiles() throws Exception { initPreImage("Unaffected"); String expectedUnaffectedText = initPostImage("Unaffected"); @@ -380,6 +448,14 @@ public class PatchApplierTest { verifyChange(result, "X"); verifyContent(result, "Unaffected", expectedUnaffectedText); } + + @Test + public void testConflictFails() throws Exception { + init("conflict"); + + Result result = applyPatch(); + assertEquals(1, result.getErrors().size()); + } } public static class InCore extends Base { @@ -726,14 +802,6 @@ public class PatchApplierTest { } @Test - public void testEditExample() throws Exception { - init("z_e", true, true); - - Result result = applyPatch(); - verifyChange(result, "z_e"); - } - - @Test public void testEditNoNewline() throws Exception { init("z_e_no_nl", true, true); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/revwalk/RevWalkCommitGraphTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/revwalk/RevWalkCommitGraphTest.java index 97d3f81b9b..3cc0368943 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/revwalk/RevWalkCommitGraphTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/revwalk/RevWalkCommitGraphTest.java @@ -10,6 +10,7 @@ package org.eclipse.jgit.revwalk; +import static java.util.Arrays.asList; import static org.eclipse.jgit.internal.storage.commitgraph.CommitGraph.EMPTY; import static org.junit.Assert.assertArrayEquals; import static org.junit.Assert.assertEquals; @@ -18,12 +19,15 @@ import static org.junit.Assert.assertNotNull; import static org.junit.Assert.assertNull; import static org.junit.Assert.assertTrue; +import java.io.IOException; import java.util.ArrayList; import java.util.Collections; +import java.util.Comparator; import java.util.List; import org.eclipse.jgit.api.Git; import org.eclipse.jgit.internal.storage.file.GC; +import org.eclipse.jgit.lib.AnyObjectId; import org.eclipse.jgit.lib.ConfigConstants; import org.eclipse.jgit.lib.Constants; import org.eclipse.jgit.lib.Ref; @@ -254,6 +258,95 @@ public class RevWalkCommitGraphTest extends RevWalkTestCase { testRevWalkBehavior("commits/8", "merge/2"); } + @Test + public void testMergedInto() throws Exception { + RevCommit c1 = commit(); + Ref branch1 = branch(c1, "commits/1"); + RevCommit c2 = commit(c1); + Ref branch2 = branch(c2, "commits/2"); + RevCommit c3 = commit(c2); + Ref branch3 = branch(c3, "commits/3"); + RevCommit c4 = commit(c1); + Ref branch4 = branch(c4, "commits/4"); + RevCommit c5 = commit(c4); + Ref branch5 = branch(c5, "commits/5"); + enableAndWriteCommitGraph(); + RevCommit c6 = commit(c1); + Ref branch6 = branch(c6, "commits/6"); + RevCommit c7 = commit(c2, c4); + Ref branch7 = branch(c7, "commits/7"); + RevCommit c8 = commit(c5); + Ref branch8 = branch(c8, "commits/8"); + RevCommit c9 = commit(c4, c6); + Ref branch9 = branch(c9, "commits/9"); + + /* + * <pre> + * current graph structure: + * 8 + * | + * 3 7 5 9 + * |/ \|/ \ + * 2 4 6 + * |___/____/ + * 1 + * </pre> + * + * [6, 7, 8, 9] are not in commit-graph. + */ + + reinitializeRevWalk(); + assertFalse(isObjectIdInGraph(c9)); + assertRefsEquals(asList(branch9), allMergedInto(c9)); + + assertFalse(isObjectIdInGraph(c8)); + assertRefsEquals(asList(branch8), allMergedInto(c8)); + + assertFalse(isObjectIdInGraph(c7)); + assertRefsEquals(asList(branch7), allMergedInto(c7)); + + assertFalse(isObjectIdInGraph(c6)); + assertRefsEquals(asList(branch6, branch9), allMergedInto(c6)); + + assertTrue(isObjectIdInGraph(c5)); + assertRefsEquals(asList(branch5, branch8), allMergedInto(c5)); + + assertTrue(isObjectIdInGraph(c4)); + assertRefsEquals(asList(branch4, branch5, branch7, branch8, branch9), + allMergedInto(c4)); + + assertTrue(isObjectIdInGraph(c3)); + assertRefsEquals(asList(branch3), allMergedInto(c3)); + + assertTrue(isObjectIdInGraph(c2)); + assertRefsEquals(asList(branch2, branch3, branch7), allMergedInto(c2)); + + assertTrue(isObjectIdInGraph(c1)); + assertRefsEquals(asList(branch1, branch2, branch3, branch4, branch5, + branch6, branch7, branch8, branch9), allMergedInto(c1)); + } + + boolean isObjectIdInGraph(AnyObjectId id) { + return rw.commitGraph().findGraphPosition(id) >= 0; + } + + List<Ref> allMergedInto(RevCommit needle) throws IOException { + List<Ref> refs = db.getRefDatabase().getRefs(); + return rw.getMergedInto(rw.lookupCommit(needle), refs); + } + + void assertRefsEquals(List<Ref> expecteds, List<Ref> actuals) { + assertEquals(expecteds.size(), actuals.size()); + Collections.sort(expecteds, Comparator.comparing(Ref::getName)); + Collections.sort(actuals, Comparator.comparing(Ref::getName)); + for (int i = 0; i < expecteds.size(); i++) { + Ref expected = expecteds.get(i); + Ref actual = actuals.get(i); + assertEquals(expected.getName(), actual.getName()); + assertEquals(expected.getObjectId(), actual.getObjectId()); + } + } + void testRevWalkBehavior(String branch, String compare) throws Exception { assertCommits( travel(TreeFilter.ALL, RevFilter.MERGE_BASE, RevSort.NONE, true, diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/UploadPackTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/UploadPackTest.java index 61458dddfb..9755ed1b69 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/UploadPackTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/UploadPackTest.java @@ -22,9 +22,12 @@ import java.util.Arrays; import java.util.Collection; import java.util.Collections; import java.util.HashMap; +import java.util.HashSet; import java.util.List; import java.util.Map; import java.util.Objects; +import java.util.Set; +import java.util.concurrent.atomic.AtomicReference; import java.util.function.Consumer; import org.eclipse.jgit.dircache.DirCache; @@ -53,6 +56,7 @@ import org.eclipse.jgit.revwalk.RevCommit; import org.eclipse.jgit.revwalk.RevTag; import org.eclipse.jgit.revwalk.RevTree; import org.eclipse.jgit.storage.pack.PackStatistics; +import org.eclipse.jgit.transport.BasePackFetchConnection.FetchConfig; import org.eclipse.jgit.transport.UploadPack.RequestPolicy; import org.eclipse.jgit.util.io.NullOutputStream; import org.junit.After; @@ -63,6 +67,8 @@ import org.junit.Test; * Tests for server upload-pack utilities. */ public class UploadPackTest { + private static final int MAX_HAVES = 64; + private URIish uri; private TestProtocol<Object> testProtocol; @@ -87,6 +93,7 @@ public class UploadPackTest { @After public void tearDown() { + TestProtocol.setFetchConfig(null); Transport.unregister(testProtocol); } @@ -2158,6 +2165,231 @@ public class UploadPackTest { assertFalse(client.getObjectDatabase().has(three.toObjectId())); } + /** + * <pre> + * remote: + * foo <- foofoo <-- branchFoo + * bar <- barbar <-- branchBar + * + * client: + * foo <-- branchFoo + * bar <-- branchBar + * + * fetch(branchFoo) should send exactly 1 have (i.e. foo) from branchFoo + * </pre> + */ + @Test + public void testNegotiationTip() throws Exception { + RevCommit fooParent = remote.commit().message("foo").create(); + RevCommit fooChild = remote.commit().message("foofoo").parent(fooParent) + .create(); + RevCommit barParent = remote.commit().message("bar").create(); + RevCommit barChild = remote.commit().message("barbar").parent(barParent) + .create(); + + // Remote has branchFoo at fooChild and branchBar at barChild + remote.update("branchFoo", fooChild); + remote.update("branchBar", barChild); + + AtomicReference<UploadPack> uploadPack = new AtomicReference<>(); + CountHavesPreUploadHook countHavesHook = new CountHavesPreUploadHook(); + RevCommit localFooParent = null; + + // Client has lagging branchFoo at fooParent and branchBar at barParent + try (TestRepository<InMemoryRepository> clientRepo = new TestRepository<>( + client)) { + localFooParent = clientRepo.commit().message("foo") + .create(); + RevCommit localBarParent = clientRepo.commit().message("bar") + .create(); + + clientRepo.update("branchFoo", localFooParent); + clientRepo.update("branchBar", localBarParent); + + testProtocol = new TestProtocol<>((Object req, Repository db) -> { + UploadPack up = new UploadPack(db); + up.setPreUploadHook(countHavesHook); + uploadPack.set(up); + return up; + }, null); + + uri = testProtocol.register(ctx, server); + + TestProtocol.setFetchConfig(new FetchConfig(true, MAX_HAVES, true)); + try (Transport tn = testProtocol.open(uri, + clientRepo.getRepository(), "server")) { + + tn.fetch(NullProgressMonitor.INSTANCE, Collections + .singletonList(new RefSpec("refs/heads/branchFoo")), + "branchFoo"); + } + } + + assertTrue(client.getObjectDatabase().has(fooParent.toObjectId())); + assertTrue(client.getObjectDatabase().has(fooChild.toObjectId())); + assertFalse(client.getObjectDatabase().has(barChild.toObjectId())); + + assertEquals(1, uploadPack.get().getStatistics().getHaves()); + assertTrue(countHavesHook.havesSentDuringNegotiation + .contains(localFooParent.toObjectId())); + } + + /** + * Remote has 2 branches branchFoo and branchBar, each of them have 128 (2 x + * MAX_HAVES) commits each. Local has both the branches with lagging + * commits. Only 64 (1 x MAX_HAVES) from each branch and lagging 64. + * fetch(branchFoo) should send all 64 (MAX_HAVES) commits on branchFoo as + * haves and none from branchBar. + * + * Visual representation of the same: + * + * <pre> + * remote: + * parent + * / \ + * branchFoo-0 branchBar-0 + * branchFoo-1 branchBar-1 + * ... ... + * ... ... + * branchFoo-128 branchBar-128 + * ^-- branchFoo ^--branchBar + * + * local: + * parent + * / \ + * branchFoo-0 branchBar-0 + * branchFoo-1 branchBar-1 + * ... ... + * ... ... + * branchFoo-64 branchBar-64 + * ^-- branchFoo ^--branchBar + * + * fetch(branchFoo) should send all 64 (MAX_HAVES) commits on branchFoo as haves + * </pre> + */ + @Test + public void testNegotiationTipWithLongerHistoryThanMaxHaves() + throws Exception { + Set<RevCommit> remoteFooCommits = new HashSet<>(); + Set<RevCommit> remoteBarCommits = new HashSet<>(); + + RevCommit parent = remote.commit().message("branchFoo-0").create(); + RevCommit parentFoo = parent; + remoteFooCommits.add(parentFoo); + for (int i = 1; i < 2 * MAX_HAVES; i++) { + RevCommit child = remote.commit() + .message("branchFoo-" + Integer.toString(i)) + .parent(parentFoo) + .create(); + parentFoo = child; + remoteFooCommits.add(parentFoo); + + } + remote.update("branchFoo", parentFoo); + + RevCommit parentBar = parent; + remoteBarCommits.add(parentBar); + for (int i = 1; i < 2 * MAX_HAVES; i++) { + RevCommit child = remote.commit() + .message("branchBar-" + Integer.toString(i)) + .parent(parentBar) + .create(); + parentBar = child; + remoteBarCommits.add(parentBar); + } + remote.update("branchBar", parentBar); + + AtomicReference<UploadPack> uploadPack = new AtomicReference<>(); + CountHavesPreUploadHook countHavesHook = new CountHavesPreUploadHook(); + Set<ObjectId> localFooCommits = new HashSet<>(); + + try (TestRepository<InMemoryRepository> clientRepo = new TestRepository<>( + client)) { + RevCommit localParent = clientRepo.commit().message("branchBar-0") + .create(); + RevCommit localParentFoo = localParent; + localFooCommits.add(localParentFoo); + for (int i = 1; i < 1 * MAX_HAVES; i++) { + RevCommit child = clientRepo.commit() + .message("branchFoo-" + Integer.toString(i)) + .parent(localParentFoo).create(); + localParentFoo = child; + localFooCommits.add(localParentFoo); + } + clientRepo.update("branchFoo", localParentFoo); + + RevCommit localParentBar = localParent; + for (int i = 1; i < 1 * MAX_HAVES; i++) { + RevCommit child = clientRepo.commit() + .message("branchBar-" + Integer.toString(i)) + .parent(localParentBar).create(); + localParentBar = child; + } + clientRepo.update("branchBar", localParentBar); + + testProtocol = new TestProtocol<>((Object req, Repository db) -> { + UploadPack up = new UploadPack(db); + up.setPreUploadHook(countHavesHook); + uploadPack.set(up); + return up; + }, null); + + uri = testProtocol.register(ctx, server); + TestProtocol.setFetchConfig(new FetchConfig(true, MAX_HAVES, true)); + try (Transport tn = testProtocol.open(uri, + clientRepo.getRepository(), "server")) { + + tn.fetch(NullProgressMonitor.INSTANCE, Collections + .singletonList(new RefSpec("refs/heads/branchFoo")), + "branchFoo"); + } + } + + for (RevCommit c : remoteFooCommits) { + assertTrue(c.toObjectId() + "", + client.getObjectDatabase().has(c.toObjectId())); + } + remoteBarCommits.remove(parent); + for (RevCommit c : remoteBarCommits) { + assertFalse(client.getObjectDatabase().has(c.toObjectId())); + } + + assertEquals(MAX_HAVES, uploadPack.get().getStatistics().getHaves()); + // Verify that all the haves that were sent during negotiation are local + // commits from branchFoo + for (Object id : countHavesHook.havesSentDuringNegotiation) { + assertTrue(localFooCommits.contains(id)); + } + } + + private static class CountHavesPreUploadHook implements PreUploadHook { + Set<ObjectId> havesSentDuringNegotiation = new HashSet<>(); + + @Override + public void onSendPack(UploadPack unusedUploadPack, + Collection<? extends ObjectId> unusedWants, + Collection<? extends ObjectId> haves) + throws ServiceMayNotContinueException { + // record haves + havesSentDuringNegotiation.addAll(haves); + } + + @Override + public void onEndNegotiateRound(UploadPack unusedUploadPack, + Collection<? extends ObjectId> unusedWants, int unusedCntCommon, + int unusedCntNotFound, boolean unusedReady) + throws ServiceMayNotContinueException { + // Do nothing. + } + + @Override + public void onBeginNegotiateRound(UploadPack unusedUploadPack, + Collection<? extends ObjectId> unusedWants, + int unusedCntOffered) throws ServiceMayNotContinueException { + // Do nothing. + } + } + @Test public void testV2FetchBadWantRef() throws Exception { RevCommit one = remote.commit().message("1").create(); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/IntListTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/IntListTest.java index 6f4292c05e..651245a083 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/IntListTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/IntListTest.java @@ -15,6 +15,7 @@ import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertTrue; import static org.junit.Assert.fail; +import org.eclipse.jgit.util.IntList.IntComparator; import org.junit.Test; public class IntListTest { @@ -43,6 +44,15 @@ public class IntListTest { } @Test + public void testFilledWithRange() { + IntList list = IntList.filledWithRange(-2, 13); + assertEquals(15, list.size()); + for (int i = 0; i < list.size(); i++) { + assertEquals(i - 2, list.get(i)); + } + } + + @Test public void testAdd_SmallGroup() { final IntList i = new IntList(); final int n = 5; @@ -164,6 +174,22 @@ public class IntListTest { } @Test + public void testSort_byAbs() { + IntList list = new IntList(); + list.add(-3); + list.add(-2); + list.add(0); + list.add(1); + list.add(4); + list.add(1); + list.sort(new AbsIntComparator()); + int[] expected = { 0, 1, 1, -2, -3, 4 }; + for (int i = 0; i < list.size(); i++) { + assertEquals(expected[i], list.get(i)); + } + } + + @Test public void testToString() { final IntList i = new IntList(); i.add(1); @@ -173,4 +199,12 @@ public class IntListTest { assertEquals("[1, 13, 5]", i.toString()); } + private static class AbsIntComparator implements IntComparator { + private AbsIntComparator() { + } + + public int compare(int a, int b) { + return Math.abs(a) - Math.abs(b); + } + } } diff --git a/org.eclipse.jgit.ui/META-INF/MANIFEST.MF b/org.eclipse.jgit.ui/META-INF/MANIFEST.MF index 2e61a7b49e..109b110f49 100644 --- a/org.eclipse.jgit.ui/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.ui/META-INF/MANIFEST.MF @@ -4,14 +4,14 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.ui Bundle-SymbolicName: org.eclipse.jgit.ui -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-RequiredExecutionEnvironment: JavaSE-11 -Export-Package: org.eclipse.jgit.awtui;version="6.5.1" -Import-Package: org.eclipse.jgit.errors;version="[6.5.1,6.6.0)", - org.eclipse.jgit.lib;version="[6.5.1,6.6.0)", - org.eclipse.jgit.nls;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revplot;version="[6.5.1,6.6.0)", - org.eclipse.jgit.revwalk;version="[6.5.1,6.6.0)", - org.eclipse.jgit.transport;version="[6.5.1,6.6.0)", - org.eclipse.jgit.util;version="[6.5.1,6.6.0)" +Export-Package: org.eclipse.jgit.awtui;version="6.6.0" +Import-Package: org.eclipse.jgit.errors;version="[6.6.0,6.7.0)", + org.eclipse.jgit.lib;version="[6.6.0,6.7.0)", + org.eclipse.jgit.nls;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revplot;version="[6.6.0,6.7.0)", + org.eclipse.jgit.revwalk;version="[6.6.0,6.7.0)", + org.eclipse.jgit.transport;version="[6.6.0,6.7.0)", + org.eclipse.jgit.util;version="[6.6.0,6.7.0)" diff --git a/org.eclipse.jgit.ui/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.ui/META-INF/SOURCE-MANIFEST.MF index edbf1f387a..41a5eb8469 100644 --- a/org.eclipse.jgit.ui/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.ui/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.ui - Sources Bundle-SymbolicName: org.eclipse.jgit.ui.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.5.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.ui;version="6.5.1.qualifier";roots="." +Bundle-Version: 6.6.0.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.ui;version="6.6.0.qualifier";roots="." diff --git a/org.eclipse.jgit.ui/pom.xml b/org.eclipse.jgit.ui/pom.xml index 625b7578a3..529e3f8346 100644 --- a/org.eclipse.jgit.ui/pom.xml +++ b/org.eclipse.jgit.ui/pom.xml @@ -19,7 +19,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.ui</artifactId> diff --git a/org.eclipse.jgit/META-INF/MANIFEST.MF b/org.eclipse.jgit/META-INF/MANIFEST.MF index c5b536967f..9cc316158a 100644 --- a/org.eclipse.jgit/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit/META-INF/MANIFEST.MF @@ -3,12 +3,12 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit Bundle-SymbolicName: org.eclipse.jgit -Bundle-Version: 6.5.1.qualifier +Bundle-Version: 6.6.0.qualifier Bundle-Localization: plugin Bundle-Vendor: %Bundle-Vendor Eclipse-ExtensibleAPI: true -Export-Package: org.eclipse.jgit.annotations;version="6.5.1", - org.eclipse.jgit.api;version="6.5.1"; +Export-Package: org.eclipse.jgit.annotations;version="6.6.0", + org.eclipse.jgit.api;version="6.6.0"; uses:="org.eclipse.jgit.transport, org.eclipse.jgit.notes, org.eclipse.jgit.dircache, @@ -23,18 +23,18 @@ Export-Package: org.eclipse.jgit.annotations;version="6.5.1", org.eclipse.jgit.revwalk.filter, org.eclipse.jgit.blame, org.eclipse.jgit.merge", - org.eclipse.jgit.api.errors;version="6.5.1"; + org.eclipse.jgit.api.errors;version="6.6.0"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.errors", - org.eclipse.jgit.attributes;version="6.5.1"; + org.eclipse.jgit.attributes;version="6.6.0"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.treewalk", - org.eclipse.jgit.blame;version="6.5.1"; + org.eclipse.jgit.blame;version="6.6.0"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.revwalk, org.eclipse.jgit.treewalk.filter, org.eclipse.jgit.diff", - org.eclipse.jgit.diff;version="6.5.1"; + org.eclipse.jgit.diff;version="6.6.0"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.attributes, org.eclipse.jgit.revwalk, @@ -42,53 +42,53 @@ Export-Package: org.eclipse.jgit.annotations;version="6.5.1", org.eclipse.jgit.treewalk.filter, org.eclipse.jgit.treewalk, org.eclipse.jgit.util", - org.eclipse.jgit.dircache;version="6.5.1"; + org.eclipse.jgit.dircache;version="6.6.0"; uses:="org.eclipse.jgit.events, org.eclipse.jgit.lib, org.eclipse.jgit.attributes, org.eclipse.jgit.treewalk, org.eclipse.jgit.util", - org.eclipse.jgit.errors;version="6.5.1"; + org.eclipse.jgit.errors;version="6.6.0"; uses:="org.eclipse.jgit.transport, org.eclipse.jgit.dircache, org.eclipse.jgit.lib, org.eclipse.jgit.internal.storage.pack", - org.eclipse.jgit.events;version="6.5.1"; + org.eclipse.jgit.events;version="6.6.0"; uses:="org.eclipse.jgit.lib", - org.eclipse.jgit.fnmatch;version="6.5.1", - org.eclipse.jgit.gitrepo;version="6.5.1"; + org.eclipse.jgit.fnmatch;version="6.6.0", + org.eclipse.jgit.gitrepo;version="6.6.0"; uses:="org.xml.sax.helpers, org.eclipse.jgit.api, org.eclipse.jgit.lib, org.eclipse.jgit.revwalk, org.xml.sax", - org.eclipse.jgit.gitrepo.internal;version="6.5.1";x-internal:=true, - org.eclipse.jgit.hooks;version="6.5.1";uses:="org.eclipse.jgit.lib", - org.eclipse.jgit.ignore;version="6.5.1", - org.eclipse.jgit.ignore.internal;version="6.5.1"; + org.eclipse.jgit.gitrepo.internal;version="6.6.0";x-internal:=true, + org.eclipse.jgit.hooks;version="6.6.0";uses:="org.eclipse.jgit.lib", + org.eclipse.jgit.ignore;version="6.6.0", + org.eclipse.jgit.ignore.internal;version="6.6.0"; x-friends:="org.eclipse.jgit.test", - org.eclipse.jgit.internal;version="6.5.1"; + org.eclipse.jgit.internal;version="6.6.0"; x-friends:="org.eclipse.jgit.test, org.eclipse.jgit.http.test", - org.eclipse.jgit.internal.diff;version="6.5.1"; + org.eclipse.jgit.internal.diff;version="6.6.0"; x-friends:="org.eclipse.jgit.test", - org.eclipse.jgit.internal.diffmergetool;version="6.5.1"; + org.eclipse.jgit.internal.diffmergetool;version="6.6.0"; x-friends:="org.eclipse.jgit.test, org.eclipse.jgit.pgm.test, org.eclipse.jgit.pgm, org.eclipse.egit.ui", - org.eclipse.jgit.internal.fsck;version="6.5.1"; + org.eclipse.jgit.internal.fsck;version="6.6.0"; x-friends:="org.eclipse.jgit.test", - org.eclipse.jgit.internal.revwalk;version="6.5.1"; + org.eclipse.jgit.internal.revwalk;version="6.6.0"; x-friends:="org.eclipse.jgit.test", - org.eclipse.jgit.internal.storage.commitgraph;version="6.5.1"; + org.eclipse.jgit.internal.storage.commitgraph;version="6.6.0"; x-friends:="org.eclipse.jgit.test", - org.eclipse.jgit.internal.storage.dfs;version="6.5.1"; + org.eclipse.jgit.internal.storage.dfs;version="6.6.0"; x-friends:="org.eclipse.jgit.test, org.eclipse.jgit.http.server, org.eclipse.jgit.http.test, org.eclipse.jgit.lfs.test", - org.eclipse.jgit.internal.storage.file;version="6.5.1"; + org.eclipse.jgit.internal.storage.file;version="6.6.0"; x-friends:="org.eclipse.jgit.test, org.eclipse.jgit.junit, org.eclipse.jgit.junit.http, @@ -97,34 +97,34 @@ Export-Package: org.eclipse.jgit.annotations;version="6.5.1", org.eclipse.jgit.pgm, org.eclipse.jgit.pgm.test, org.eclipse.jgit.ssh.apache", - org.eclipse.jgit.internal.storage.io;version="6.5.1"; + org.eclipse.jgit.internal.storage.io;version="6.6.0"; x-friends:="org.eclipse.jgit.junit, org.eclipse.jgit.test, org.eclipse.jgit.pgm", - org.eclipse.jgit.internal.storage.memory;version="6.5.1"; + org.eclipse.jgit.internal.storage.memory;version="6.6.0"; x-friends:="org.eclipse.jgit.test", - org.eclipse.jgit.internal.storage.pack;version="6.5.1"; + org.eclipse.jgit.internal.storage.pack;version="6.6.0"; x-friends:="org.eclipse.jgit.junit, org.eclipse.jgit.test, org.eclipse.jgit.pgm", - org.eclipse.jgit.internal.storage.reftable;version="6.5.1"; + org.eclipse.jgit.internal.storage.reftable;version="6.6.0"; x-friends:="org.eclipse.jgit.http.test, org.eclipse.jgit.junit, org.eclipse.jgit.test, org.eclipse.jgit.pgm", - org.eclipse.jgit.internal.submodule;version="6.5.1";x-internal:=true, - org.eclipse.jgit.internal.transport.connectivity;version="6.5.1"; + org.eclipse.jgit.internal.submodule;version="6.6.0";x-internal:=true, + org.eclipse.jgit.internal.transport.connectivity;version="6.6.0"; x-friends:="org.eclipse.jgit.test", - org.eclipse.jgit.internal.transport.http;version="6.5.1"; + org.eclipse.jgit.internal.transport.http;version="6.6.0"; x-friends:="org.eclipse.jgit.test", - org.eclipse.jgit.internal.transport.parser;version="6.5.1"; + org.eclipse.jgit.internal.transport.parser;version="6.6.0"; x-friends:="org.eclipse.jgit.http.server, org.eclipse.jgit.test", - org.eclipse.jgit.internal.transport.ssh;version="6.5.1"; + org.eclipse.jgit.internal.transport.ssh;version="6.6.0"; x-friends:="org.eclipse.jgit.ssh.apache, org.eclipse.jgit.ssh.jsch, org.eclipse.jgit.test", - org.eclipse.jgit.lib;version="6.5.1"; + org.eclipse.jgit.lib;version="6.6.0"; uses:="org.eclipse.jgit.transport, org.eclipse.jgit.util.sha1, org.eclipse.jgit.dircache, @@ -138,12 +138,12 @@ Export-Package: org.eclipse.jgit.annotations;version="6.5.1", org.eclipse.jgit.util, org.eclipse.jgit.submodule, org.eclipse.jgit.util.time", - org.eclipse.jgit.lib.internal;version="6.5.1"; + org.eclipse.jgit.lib.internal;version="6.6.0"; x-friends:="org.eclipse.jgit.test, org.eclipse.jgit.pgm, org.eclipse.egit.ui", - org.eclipse.jgit.logging;version="6.5.1", - org.eclipse.jgit.merge;version="6.5.1"; + org.eclipse.jgit.logging;version="6.6.0", + org.eclipse.jgit.merge;version="6.6.0"; uses:="org.eclipse.jgit.dircache, org.eclipse.jgit.lib, org.eclipse.jgit.revwalk, @@ -152,40 +152,40 @@ Export-Package: org.eclipse.jgit.annotations;version="6.5.1", org.eclipse.jgit.util, org.eclipse.jgit.api, org.eclipse.jgit.attributes", - org.eclipse.jgit.nls;version="6.5.1", - org.eclipse.jgit.notes;version="6.5.1"; + org.eclipse.jgit.nls;version="6.6.0", + org.eclipse.jgit.notes;version="6.6.0"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.revwalk, org.eclipse.jgit.treewalk, org.eclipse.jgit.merge", - org.eclipse.jgit.patch;version="6.5.1"; + org.eclipse.jgit.patch;version="6.6.0"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.diff", - org.eclipse.jgit.revplot;version="6.5.1"; + org.eclipse.jgit.revplot;version="6.6.0"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.revwalk", - org.eclipse.jgit.revwalk;version="6.5.1"; + org.eclipse.jgit.revwalk;version="6.6.0"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.diff, org.eclipse.jgit.treewalk.filter, org.eclipse.jgit.revwalk.filter, org.eclipse.jgit.treewalk", - org.eclipse.jgit.revwalk.filter;version="6.5.1"; + org.eclipse.jgit.revwalk.filter;version="6.6.0"; uses:="org.eclipse.jgit.revwalk, org.eclipse.jgit.lib, org.eclipse.jgit.util", - org.eclipse.jgit.storage.file;version="6.5.1"; + org.eclipse.jgit.storage.file;version="6.6.0"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.util", - org.eclipse.jgit.storage.pack;version="6.5.1"; + org.eclipse.jgit.storage.pack;version="6.6.0"; uses:="org.eclipse.jgit.lib", - org.eclipse.jgit.submodule;version="6.5.1"; + org.eclipse.jgit.submodule;version="6.6.0"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.diff, org.eclipse.jgit.treewalk.filter, org.eclipse.jgit.treewalk, org.eclipse.jgit.util", - org.eclipse.jgit.transport;version="6.5.1"; + org.eclipse.jgit.transport;version="6.6.0"; uses:="javax.crypto, org.eclipse.jgit.util.io, org.eclipse.jgit.lib, @@ -198,21 +198,21 @@ Export-Package: org.eclipse.jgit.annotations;version="6.5.1", org.eclipse.jgit.transport.resolver, org.eclipse.jgit.storage.pack, org.eclipse.jgit.errors", - org.eclipse.jgit.transport.http;version="6.5.1"; + org.eclipse.jgit.transport.http;version="6.6.0"; uses:="javax.net.ssl", - org.eclipse.jgit.transport.resolver;version="6.5.1"; + org.eclipse.jgit.transport.resolver;version="6.6.0"; uses:="org.eclipse.jgit.transport, org.eclipse.jgit.lib", - org.eclipse.jgit.treewalk;version="6.5.1"; + org.eclipse.jgit.treewalk;version="6.6.0"; uses:="org.eclipse.jgit.dircache, org.eclipse.jgit.lib, org.eclipse.jgit.attributes, org.eclipse.jgit.revwalk, org.eclipse.jgit.treewalk.filter, org.eclipse.jgit.util", - org.eclipse.jgit.treewalk.filter;version="6.5.1"; + org.eclipse.jgit.treewalk.filter;version="6.6.0"; uses:="org.eclipse.jgit.treewalk", - org.eclipse.jgit.util;version="6.5.1"; + org.eclipse.jgit.util;version="6.6.0"; uses:="org.eclipse.jgit.transport, org.eclipse.jgit.hooks, org.eclipse.jgit.revwalk, @@ -225,12 +225,12 @@ Export-Package: org.eclipse.jgit.annotations;version="6.5.1", org.eclipse.jgit.treewalk, javax.net.ssl, org.eclipse.jgit.util.time", - org.eclipse.jgit.util.io;version="6.5.1"; + org.eclipse.jgit.util.io;version="6.6.0"; uses:="org.eclipse.jgit.attributes, org.eclipse.jgit.lib, org.eclipse.jgit.treewalk", - org.eclipse.jgit.util.sha1;version="6.5.1", - org.eclipse.jgit.util.time;version="6.5.1" + org.eclipse.jgit.util.sha1;version="6.6.0", + org.eclipse.jgit.util.time;version="6.6.0" Bundle-RequiredExecutionEnvironment: JavaSE-11 Import-Package: com.googlecode.javaewah;version="[1.1.6,2.0.0)", javax.crypto, diff --git a/org.eclipse.jgit/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit/META-INF/SOURCE-MANIFEST.MF index ab07518e56..407d45c748 100644 --- a/org.eclipse.jgit/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit - Sources Bundle-SymbolicName: org.eclipse.jgit.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.5.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit;version="6.5.1.qualifier";roots="." +Bundle-Version: 6.6.0.qualifier +Eclipse-SourceBundle: org.eclipse.jgit;version="6.6.0.qualifier";roots="." diff --git a/org.eclipse.jgit/pom.xml b/org.eclipse.jgit/pom.xml index 48f232788a..100a2ff0ca 100644 --- a/org.eclipse.jgit/pom.xml +++ b/org.eclipse.jgit/pom.xml @@ -20,7 +20,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit</artifactId> diff --git a/org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties b/org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties index faea9cbea3..78dd9bd4c3 100644 --- a/org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties +++ b/org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties @@ -17,7 +17,14 @@ applyBinaryBaseOidWrong=Cannot apply binary patch; OID for file {0} does not mat applyBinaryForInCoreNotSupported=Applying binary patch for inCore repositories is not yet supported applyBinaryOidTooShort=Binary patch for file {0} does not have full IDs applyBinaryPatchTypeNotSupported=Couldn't apply binary patch of type {0} -applyBinaryResultOidWrong=Result of binary patch for file {0} has wrong OID. +applyTextPatchCannotApplyHunk=Hunk cannot be applied +applyTextPatchSingleClearingHunk=Expected a single hunk for clearing all content +applyBinaryResultOidWrong=Result of binary patch for file {0} has wrong OID +applyPatchWithoutSourceOnAlreadyExistingSource=Cannot perform {0} action on an existing file +applyPatchWithCreationOverAlreadyExistingDestination=Cannot perform {0} action which overrides an existing file +applyPatchWithSourceOnNonExistentSource=Cannot perform {0} action on a non-existent file +applyTextPatchUnorderedHunkApplications=Current hunk must be applied after the last hunk +applyTextPatchUnorderedHunks=Got unordered hunks applyingCommit=Applying {0} archiveFormatAlreadyAbsent=Archive format already absent: {0} archiveFormatAlreadyRegistered=Archive format already registered with different implementation: {0} @@ -581,6 +588,8 @@ packWasDeleted=Pack file {0} was deleted, removing it from pack list packWriterStatistics=Total {0,number,#0} (delta {1,number,#0}), reused {2,number,#0} (delta {3,number,#0}) panicCantRenameIndexFile=Panic: index file {0} must be renamed to replace {1}; until then repository is corrupt patchApplyException=Cannot apply: {0} +patchApplyErrorWithHunk=Error applying patch in {0}, hunk {1}: {2} +patchApplyErrorWithoutHunk=Error applying patch in {0}: {1} patchFormatException=Format error: {0} pathNotConfigured=Submodule path is not configured peeledLineBeforeRef=Peeled line before ref. diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/ApplyCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/ApplyCommand.java index 49f225f319..e612924771 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/ApplyCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/ApplyCommand.java @@ -10,10 +10,16 @@ package org.eclipse.jgit.api; import java.io.File; +import java.io.IOException; import java.io.InputStream; +import java.text.MessageFormat; + import org.eclipse.jgit.api.errors.GitAPIException; +import org.eclipse.jgit.api.errors.PatchApplyException; +import org.eclipse.jgit.api.errors.PatchFormatException; import org.eclipse.jgit.internal.JGitText; import org.eclipse.jgit.lib.Repository; +import org.eclipse.jgit.patch.Patch; import org.eclipse.jgit.patch.PatchApplier; import org.eclipse.jgit.patch.PatchApplier.Result; @@ -67,11 +73,31 @@ public class ApplyCommand extends GitCommand<ApplyResult> { public ApplyResult call() throws GitAPIException { checkCallable(); setCallable(false); + Patch patch = new Patch(); + try (InputStream inStream = in) { + patch.parse(inStream); + if (!patch.getErrors().isEmpty()) { + throw new PatchFormatException(patch.getErrors()); + } + } catch (IOException e) { + throw new PatchApplyException(MessageFormat.format( + JGitText.get().patchApplyException, e.getMessage()), e); + } ApplyResult r = new ApplyResult(); - PatchApplier patchApplier = new PatchApplier(repo); - Result applyResult = patchApplier.applyPatch(in); - for (String p : applyResult.getPaths()) { - r.addUpdatedFile(new File(repo.getWorkTree(), p)); + try { + PatchApplier patchApplier = new PatchApplier(repo); + Result applyResult = patchApplier.applyPatch(patch); + if (!applyResult.getErrors().isEmpty()) { + throw new PatchApplyException( + MessageFormat.format(JGitText.get().patchApplyException, + applyResult.getErrors())); + } + for (String p : applyResult.getPaths()) { + r.addUpdatedFile(new File(repo.getWorkTree(), p)); + } + } catch (IOException e) { + throw new PatchApplyException(MessageFormat.format(JGitText.get().patchApplyException, + e.getMessage(), e)); } return r; } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/ListTagCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/ListTagCommand.java index d7b34ab7f5..27a5288429 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/ListTagCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/ListTagCommand.java @@ -16,9 +16,13 @@ import java.util.List; import org.eclipse.jgit.api.errors.GitAPIException; import org.eclipse.jgit.api.errors.JGitInternalException; +import org.eclipse.jgit.errors.IncorrectObjectTypeException; +import org.eclipse.jgit.errors.MissingObjectException; +import org.eclipse.jgit.lib.AnyObjectId; import org.eclipse.jgit.lib.Constants; import org.eclipse.jgit.lib.Ref; import org.eclipse.jgit.lib.Repository; +import org.eclipse.jgit.revwalk.RevCommit; import org.eclipse.jgit.revwalk.RevWalk; /** @@ -29,6 +33,9 @@ import org.eclipse.jgit.revwalk.RevWalk; */ public class ListTagCommand extends GitCommand<List<Ref>> { + private final RevWalk rw; + private RevCommit commit; + /** * Constructor for ListTagCommand. * @@ -37,21 +44,49 @@ public class ListTagCommand extends GitCommand<List<Ref>> { */ protected ListTagCommand(Repository repo) { super(repo); + rw = new RevWalk(repo); + } + + /** + * Only list tags which contain the specified commit. + * + * @param commit + * the specified commit + * @return this command + * @throws IOException + * @throws IncorrectObjectTypeException + * @throws MissingObjectException + * + * @since 6.6 + */ + public ListTagCommand setContains(AnyObjectId commit) + throws MissingObjectException, IncorrectObjectTypeException, + IOException { + checkCallable(); + this.commit = rw.parseCommit(commit); + return this; } /** {@inheritDoc} */ @Override public List<Ref> call() throws GitAPIException { checkCallable(); - List<Ref> tags = new ArrayList<>(); - try (RevWalk revWalk = new RevWalk(repo)) { + List<Ref> tags; + try { List<Ref> refList = repo.getRefDatabase() .getRefsByPrefix(Constants.R_TAGS); - for (Ref ref : refList) { - tags.add(ref); + if (commit != null) { + // if body is retained #getMergedInto needs to access data not + // available in commit graph which is slower + rw.setRetainBody(false); + tags = rw.getMergedInto(commit, refList); + } else { + tags = new ArrayList<>(refList); } } catch (IOException e) { throw new JGitInternalException(e.getMessage(), e); + } finally { + rw.close(); } Collections.sort(tags, (Ref o1, Ref o2) -> o1.getName().compareTo(o2.getName())); diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/JGitText.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/JGitText.java index 39cc749cc4..28634cbc4d 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/JGitText.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/JGitText.java @@ -46,6 +46,14 @@ public class JGitText extends TranslationBundle { /***/ public String applyBinaryOidTooShort; /***/ public String applyBinaryPatchTypeNotSupported; /***/ public String applyBinaryResultOidWrong; + /***/ public String applyPatchWithoutSourceOnAlreadyExistingSource; + /***/ public String applyPatchWithCreationOverAlreadyExistingDestination; + /***/ public String applyPatchWithSourceOnNonExistentSource; + /***/ public String applyTextPatchCannotApplyHunk; + /***/ public String applyTextPatchSingleClearingHunk; + /***/ public String applyTextPatchUnorderedHunkApplications; + /***/ public String applyTextPatchUnorderedHunks; + /***/ public String applyingCommit; /***/ public String archiveFormatAlreadyAbsent; /***/ public String archiveFormatAlreadyRegistered; @@ -609,6 +617,8 @@ public class JGitText extends TranslationBundle { /***/ public String packWriterStatistics; /***/ public String panicCantRenameIndexFile; /***/ public String patchApplyException; + /***/ public String patchApplyErrorWithHunk; + /***/ public String patchApplyErrorWithoutHunk; /***/ public String patchFormatException; /***/ public String pathNotConfigured; /***/ public String peeledLineBeforeRef; diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackFile.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackFile.java index 411777c7ad..c745b8e6ee 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackFile.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackFile.java @@ -1042,15 +1042,7 @@ public final class DfsPackFile extends BlockBasedFile { ctx.stats.readIdx++; long start = System.nanoTime(); try (ReadableChannel rc = ctx.db.openFile(desc, INDEX)) { - InputStream in = Channels.newInputStream(rc); - int wantSize = 8192; - int bs = rc.blockSize(); - if (0 < bs && bs < wantSize) { - bs = (wantSize / bs) * bs; - } else if (bs <= 0) { - bs = wantSize; - } - PackIndex idx = PackIndex.read(new BufferedInputStream(in, bs)); + PackIndex idx = PackIndex.read(alignTo8kBlocks(rc)); ctx.stats.readIdxBytes += rc.position(); index = idx; return new DfsBlockCache.Ref<>( @@ -1094,17 +1086,8 @@ public final class DfsPackFile extends BlockBasedFile { long size; PackBitmapIndex bmidx; try { - InputStream in = Channels.newInputStream(rc); - int wantSize = 8192; - int bs = rc.blockSize(); - if (0 < bs && bs < wantSize) { - bs = (wantSize / bs) * bs; - } else if (bs <= 0) { - bs = wantSize; - } - in = new BufferedInputStream(in, bs); - bmidx = PackBitmapIndex.read(in, () -> idx(ctx), - () -> getReverseIdx(ctx), + bmidx = PackBitmapIndex.read(alignTo8kBlocks(rc), + () -> idx(ctx), () -> getReverseIdx(ctx), ctx.getOptions().shouldLoadRevIndexInParallel()); } finally { size = rc.position(); @@ -1133,16 +1116,7 @@ public final class DfsPackFile extends BlockBasedFile { long size; CommitGraph cg; try { - InputStream in = Channels.newInputStream(rc); - int wantSize = 8192; - int bs = rc.blockSize(); - if (0 < bs && bs < wantSize) { - bs = (wantSize / bs) * bs; - } else if (bs <= 0) { - bs = wantSize; - } - in = new BufferedInputStream(in, bs); - cg = CommitGraphLoader.read(in); + cg = CommitGraphLoader.read(alignTo8kBlocks(rc)); } finally { size = rc.position(); ctx.stats.readCommitGraphBytes += size; @@ -1157,4 +1131,19 @@ public final class DfsPackFile extends BlockBasedFile { e); } } + + private static InputStream alignTo8kBlocks(ReadableChannel rc) { + // TODO(ifrade): This is not reading from DFS, so the channel should + // know better the right blocksize. I don't know why this was done in + // the first place, verify and remove if not needed. + InputStream in = Channels.newInputStream(rc); + int wantSize = 8192; + int bs = rc.blockSize(); + if (0 < bs && bs < wantSize) { + bs = (wantSize / bs) * bs; + } else if (bs <= 0) { + bs = wantSize; + } + return new BufferedInputStream(in, bs); + } } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackedBatchRefUpdate.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackedBatchRefUpdate.java index 8b0ea4fcd6..106313db63 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackedBatchRefUpdate.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackedBatchRefUpdate.java @@ -158,36 +158,40 @@ class PackedBatchRefUpdate extends BatchRefUpdate { } Map<String, LockFile> locks = null; + LockFile packedRefsLock = null; refdb.inProcessPackedRefsLock.lock(); try { - PackedRefList oldPackedList; + // During clone locking isn't needed since no refs exist yet. + // This also helps to avoid problems with refs only differing in + // case on a case insensitive filesystem (bug 528497) if (!refdb.isInClone() && shouldLockLooseRefs) { locks = lockLooseRefs(pending); if (locks == null) { return; } - oldPackedList = refdb.pack(locks); - } else { - // During clone locking isn't needed since no refs exist yet. - // This also helps to avoid problems with refs only differing in - // case on a case insensitive filesystem (bug 528497) - oldPackedList = refdb.getPackedRefs(); + refdb.pack(locks); } + + packedRefsLock = refdb.lockPackedRefsOrThrow(); + PackedRefList oldPackedList = refdb.refreshPackedRefs(); RefList<Ref> newRefs = applyUpdates(walk, oldPackedList, pending); if (newRefs == null) { return; } - LockFile packedRefsLock = refdb.lockPackedRefs(); - if (packedRefsLock == null) { - lockFailure(pending.get(0), pending); - return; - } - // commitPackedRefs removes lock file (by renaming over real file). refdb.commitPackedRefs(packedRefsLock, newRefs, oldPackedList, true); + } catch (LockFailedException e) { + lockFailure(pending.get(0), pending); + return; } finally { try { unlockAll(locks); + if (packedRefsLock != null) { + // This will be no-op if commitPackedRefs is successful as + // it will remove the lock file (by renaming over real + // file). + packedRefsLock.unlock(); + } } finally { refdb.inProcessPackedRefsLock.unlock(); } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/RefDirectory.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/RefDirectory.java index 065c20b616..0416a648e5 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/RefDirectory.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/RefDirectory.java @@ -179,6 +179,19 @@ public class RefDirectory extends RefDatabase { private final TrustPackedRefsStat trustPackedRefsStat; + RefDirectory(RefDirectory refDb) { + parent = refDb.parent; + gitDir = refDb.gitDir; + refsDir = refDb.refsDir; + logsDir = refDb.logsDir; + logsRefsDir = refDb.logsRefsDir; + packedRefsFile = refDb.packedRefsFile; + looseRefs.set(refDb.looseRefs.get()); + packedRefs.set(refDb.packedRefs.get()); + trustFolderStat = refDb.trustFolderStat; + trustPackedRefsStat = refDb.trustPackedRefsStat; + } + RefDirectory(FileRepository db) { final FS fs = db.getFS(); parent = db; @@ -223,6 +236,15 @@ public class RefDirectory extends RefDatabase { return new File(logsDir, name); } + /** + * Create a cache of this {@link RefDirectory}. + * + * @return a cached RefDirectory. + */ + public SnapshottingRefDirectory createSnapshottingRefDirectory() { + return new SnapshottingRefDirectory(this); + } + /** {@inheritDoc} */ @Override public void create() throws IOException { @@ -575,18 +597,26 @@ public class RefDirectory extends RefDatabase { else { detachingSymbolicRef = detach && ref.isSymbolic(); } - RefDirectoryUpdate refDirUpdate = new RefDirectoryUpdate(this, ref); + RefDirectoryUpdate refDirUpdate = createRefDirectoryUpdate(ref); if (detachingSymbolicRef) refDirUpdate.setDetachingSymbolicRef(); return refDirUpdate; } + RefDirectoryUpdate createRefDirectoryUpdate(Ref ref) { + return new RefDirectoryUpdate(this, ref); + } + /** {@inheritDoc} */ @Override public RefDirectoryRename newRename(String fromName, String toName) throws IOException { RefDirectoryUpdate from = newUpdate(fromName, false); RefDirectoryUpdate to = newUpdate(toName, false); + return createRefDirectoryRename(from, to); + } + + RefDirectoryRename createRefDirectoryRename(RefDirectoryUpdate from, RefDirectoryUpdate to) { return new RefDirectoryRename(from, to); } @@ -643,16 +673,16 @@ public class RefDirectory extends RefDatabase { // Write the packed-refs file using an atomic update. We might // wind up reading it twice, before and after the lock, to ensure // we don't miss an edit made externally. - final PackedRefList packed = getPackedRefs(); + PackedRefList packed = getPackedRefs(); if (packed.contains(name)) { inProcessPackedRefsLock.lock(); try { LockFile lck = lockPackedRefsOrThrow(); try { - PackedRefList cur = readPackedRefs(); - int idx = cur.find(name); + packed = refreshPackedRefs(); + int idx = packed.find(name); if (0 <= idx) { - commitPackedRefs(lck, cur.remove(idx), packed, true); + commitPackedRefs(lck, packed.remove(idx), packed, true); } } finally { lck.unlock(); @@ -697,17 +727,17 @@ public class RefDirectory extends RefDatabase { pack(refs, Collections.emptyMap()); } - PackedRefList pack(Map<String, LockFile> heldLocks) throws IOException { - return pack(heldLocks.keySet(), heldLocks); + void pack(Map<String, LockFile> heldLocks) throws IOException { + pack(heldLocks.keySet(), heldLocks); } - private PackedRefList pack(Collection<String> refs, + private void pack(Collection<String> refs, Map<String, LockFile> heldLocks) throws IOException { for (LockFile ol : heldLocks.values()) { ol.requireLock(); } if (refs.isEmpty()) { - return null; + return; } FS fs = parent.getFS(); @@ -716,13 +746,13 @@ public class RefDirectory extends RefDatabase { try { LockFile lck = lockPackedRefsOrThrow(); try { - final PackedRefList packed = getPackedRefs(); - RefList<Ref> cur = readPackedRefs(); + PackedRefList oldPacked = refreshPackedRefs(); + RefList<Ref> newPacked = oldPacked; // Iterate over all refs to be packed boolean dirty = false; for (String refName : refs) { - Ref oldRef = readRef(refName, cur); + Ref oldRef = readRef(refName, newPacked); if (oldRef == null) { continue; // A non-existent ref is already correctly packed. } @@ -739,21 +769,20 @@ public class RefDirectory extends RefDatabase { } dirty = true; - int idx = cur.find(refName); + int idx = newPacked.find(refName); if (idx >= 0) { - cur = cur.set(idx, newRef); + newPacked = newPacked.set(idx, newRef); } else { - cur = cur.add(idx, newRef); + newPacked = newPacked.add(idx, newRef); } } if (!dirty) { // All requested refs were already packed accurately - return packed; + return; } // The new content for packed-refs is collected. Persist it. - PackedRefList result = commitPackedRefs(lck, cur, packed, - false); + commitPackedRefs(lck, newPacked, oldPacked,false); // Now delete the loose refs which are now packed for (String refName : refs) { @@ -780,7 +809,7 @@ public class RefDirectory extends RefDatabase { if (currentLooseRef == null || currentLooseRef.isSymbolic()) { continue; } - Ref packedRef = cur.get(refName); + Ref packedRef = newPacked.get(refName); ObjectId clr_oid = currentLooseRef.getObjectId(); if (clr_oid != null && clr_oid.equals(packedRef.getObjectId())) { @@ -804,7 +833,6 @@ public class RefDirectory extends RefDatabase { } // Don't fire refsChanged. The refs have not change, only their // storage. - return result; } finally { lck.unlock(); } @@ -825,7 +853,7 @@ public class RefDirectory extends RefDatabase { return null; } - private LockFile lockPackedRefsOrThrow() throws IOException { + LockFile lockPackedRefsOrThrow() throws IOException { LockFile lck = lockPackedRefs(); if (lck == null) { throw new LockFailedException(packedRefsFile); @@ -924,9 +952,18 @@ public class RefDirectory extends RefDatabase { break; } + return refreshPackedRefs(curList); + } + + PackedRefList refreshPackedRefs() throws IOException { + return refreshPackedRefs(packedRefs.get()); + } + + private PackedRefList refreshPackedRefs(PackedRefList curList) + throws IOException { final PackedRefList newList = readPackedRefs(); - if (packedRefs.compareAndSet(curList, newList) - && !curList.id.equals(newList.id)) { + if (packedRefs.compareAndSet(curList, newList) && !curList.id.equals( + newList.id)) { modCnt.incrementAndGet(); } return newList; @@ -957,6 +994,13 @@ public class RefDirectory extends RefDatabase { } } + void compareAndSetPackedRefs(PackedRefList curList, PackedRefList newList) { + if (packedRefs.compareAndSet(curList, newList) + && !curList.id.equals(newList.id)) { + modCnt.incrementAndGet(); + } + } + private RefList<Ref> parsePackedRefs(BufferedReader br) throws IOException { RefList.Builder<Ref> all = new RefList.Builder<>(); @@ -1015,12 +1059,9 @@ public class RefDirectory extends RefDatabase { return new StringBuilder(end - off).append(src, off, end).toString(); } - PackedRefList commitPackedRefs(final LockFile lck, final RefList<Ref> refs, + void commitPackedRefs(final LockFile lck, final RefList<Ref> refs, final PackedRefList oldPackedList, boolean changed) throws IOException { - // Can't just return packedRefs.get() from this method; it might have been - // updated again after writePackedRefs() returns. - AtomicReference<PackedRefList> result = new AtomicReference<>(); new RefWriter(refs) { @Override protected void writeFile(String name, byte[] content) @@ -1047,29 +1088,12 @@ public class RefDirectory extends RefDatabase { byte[] digest = Constants.newMessageDigest().digest(content); PackedRefList newPackedList = new PackedRefList( refs, lck.getCommitSnapshot(), ObjectId.fromRaw(digest)); - - // This thread holds the file lock, so no other thread or process should - // be able to modify the packed-refs file on disk. If the list changed, - // it means something is very wrong, so throw an exception. - // - // However, we can't use a naive compareAndSet to check whether the - // update was successful, because another thread might _read_ the - // packed refs file that was written out by this thread while holding - // the lock, and update the packedRefs reference to point to that. So - // compare the actual contents instead. - PackedRefList afterUpdate = packedRefs.updateAndGet( - p -> p.id.equals(oldPackedList.id) ? newPackedList : p); - if (!afterUpdate.id.equals(newPackedList.id)) { - throw new ObjectWritingException( - MessageFormat.format(JGitText.get().unableToWrite, name)); - } + packedRefs.compareAndSet(oldPackedList, newPackedList); if (changed) { modCnt.incrementAndGet(); } - result.set(newPackedList); } }.writePackedRefs(); - return result.get(); } private Ref readRef(String name, RefList<Ref> packed) throws IOException { @@ -1249,7 +1273,7 @@ public class RefDirectory extends RefDatabase { File tmp = File.createTempFile("renamed_", "_ref", refsDir); //$NON-NLS-1$ //$NON-NLS-2$ String name = Constants.R_REFS + tmp.getName(); Ref ref = new ObjectIdRef.Unpeeled(NEW, name, null); - return new RefDirectoryUpdate(this, ref); + return createRefDirectoryUpdate(ref); } /** diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/RefDirectoryRename.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/RefDirectoryRename.java index 2c0ade681b..d07299e45a 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/RefDirectoryRename.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/RefDirectoryRename.java @@ -59,6 +59,15 @@ class RefDirectoryRename extends RefRename { refdb = src.getRefDatabase(); } + /** + * Get the ref directory associated with this rename. + * + * @return the ref directory. + */ + protected RefDirectory getRefDirectory() { + return refdb; + } + /** {@inheritDoc} */ @Override protected Result doRename() throws IOException { diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/SnapshottingRefDirectory.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/SnapshottingRefDirectory.java new file mode 100644 index 0000000000..0b9748096e --- /dev/null +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/SnapshottingRefDirectory.java @@ -0,0 +1,258 @@ +/* + * Copyright (c) 2023 Qualcomm Innovation Center, Inc. + * and other copyright owners as documented in the project's IP log. + * + * This program and the accompanying materials are made available under the + * terms of the Eclipse Distribution License v. 1.0 which is available at + * https://www.eclipse.org/org/documents/edl-v10.php. + * + * SPDX-License-Identifier: BSD-3-Clause + */ + +package org.eclipse.jgit.internal.storage.file; + +import org.eclipse.jgit.lib.ProgressMonitor; +import org.eclipse.jgit.lib.Ref; +import org.eclipse.jgit.lib.RefDatabase; +import org.eclipse.jgit.lib.RefUpdate; +import org.eclipse.jgit.revwalk.RevWalk; + +import java.io.IOException; +import java.util.List; + +/** + * Snapshotting write-through cache of a {@link RefDirectory}. + * <p> + * This is intended to be short-term write-through snapshot based cache used in + * a request scope to avoid re-reading packed-refs on each read. A future + * improvement could also snapshot loose refs. + * <p> + * Only use this class when concurrent writes from other requests (not using the + * same instance of SnapshottingRefDirectory) generally need not be visible to + * the current request. The exception to this is when such writes would cause + * writes from this snapshot to fail due to their base ref value being + * outdated. + */ +class SnapshottingRefDirectory extends RefDirectory { + final RefDirectory refDb; + + private volatile boolean isValid; + + /** + * Create a snapshotting write-through cache of a {@link RefDirectory}. + * + * @param refDb + * a reference to the ref database + */ + SnapshottingRefDirectory(RefDirectory refDb) { + super(refDb); + this.refDb = refDb; + } + + /** + * Lazily initializes and returns a PackedRefList snapshot. + * <p> + * A newer snapshot will be returned when a ref update is performed using + * this {@link SnapshottingRefDirectory}. + */ + @Override + PackedRefList getPackedRefs() throws IOException { + if (!isValid) { + synchronized (this) { + if (!isValid) { + refreshSnapshot(); + } + } + } + return packedRefs.get(); + } + + /** {@inheritDoc} */ + @Override + void delete(RefDirectoryUpdate update) throws IOException { + refreshSnapshot(); + super.delete(update); + } + + /** {@inheritDoc} */ + @Override + public RefDirectoryUpdate newUpdate(String name, boolean detach) + throws IOException { + refreshSnapshot(); + return super.newUpdate(name, detach); + } + + /** {@inheritDoc} */ + @Override + public PackedBatchRefUpdate newBatchUpdate() { + return new SnapshotPackedBatchRefUpdate(this); + } + + /** {@inheritDoc} */ + @Override + public PackedBatchRefUpdate newBatchUpdate(boolean shouldLockLooseRefs) { + return new SnapshotPackedBatchRefUpdate(this, shouldLockLooseRefs); + } + + /** {@inheritDoc} */ + @Override + RefDirectoryUpdate newTemporaryUpdate() throws IOException { + refreshSnapshot(); + return super.newTemporaryUpdate(); + } + + @Override + RefDirectoryUpdate createRefDirectoryUpdate(Ref ref) { + return new SnapshotRefDirectoryUpdate(this, ref); + } + + @Override + RefDirectoryRename createRefDirectoryRename(RefDirectoryUpdate from, + RefDirectoryUpdate to) { + return new SnapshotRefDirectoryRename(from, to); + } + + synchronized void invalidateSnapshot() { + isValid = false; + } + + /** + * Refresh our snapshot by calling the underlying RefDirectory's + * getPackedRefs(). + * <p> + * Update the in-memory copy of the underlying RefDirectory's packed-refs to + * avoid the overhead of re-reading packed-refs on each new snapshot as the + * packed-refs of the underlying RefDirectory may not get updated if most + * threads use this snapshot. + * + * @throws IOException + */ + private synchronized void refreshSnapshot() throws IOException { + compareAndSetPackedRefs(packedRefs.get(), refDb.getPackedRefs()); + isValid = true; + } + + @FunctionalInterface + private interface SupplierThrowsException<R, E extends Exception> { + R call() throws E; + } + + @FunctionalInterface + private interface FunctionThrowsException<A, R, E extends Exception> { + R apply(A a) throws E; + } + + @FunctionalInterface + private interface TriConsumerThrowsException<A1, A2, A3, E extends Exception> { + void accept(A1 a1, A2 a2, A3 a3) throws E; + } + + private static <T> T invalidateSnapshotOnError( + SupplierThrowsException<T, IOException> f, RefDatabase refDb) + throws IOException { + return invalidateSnapshotOnError(a -> f.call(), null, refDb); + } + + private static <A, R> R invalidateSnapshotOnError( + FunctionThrowsException<A, R, IOException> f, A a, + RefDatabase refDb) throws IOException { + try { + return f.apply(a); + } catch (IOException e) { + ((SnapshottingRefDirectory) refDb).invalidateSnapshot(); + throw e; + } + } + + private static <A1, A2, A3> void invalidateSnapshotOnError( + TriConsumerThrowsException<A1, A2, A3, IOException> f, A1 a1, A2 a2, + A3 a3, RefDatabase refDb) throws IOException { + try { + f.accept(a1, a2, a3); + } catch (IOException e) { + ((SnapshottingRefDirectory) refDb).invalidateSnapshot(); + throw e; + } + } + + private static class SnapshotRefDirectoryUpdate extends RefDirectoryUpdate { + SnapshotRefDirectoryUpdate(RefDirectory r, Ref ref) { + super(r, ref); + } + + @Override + public Result forceUpdate() throws IOException { + return invalidateSnapshotOnError(() -> super.forceUpdate(), + getRefDatabase()); + } + + @Override + public Result update() throws IOException { + return invalidateSnapshotOnError(() -> super.update(), + getRefDatabase()); + } + + @Override + public Result update(RevWalk walk) throws IOException { + return invalidateSnapshotOnError(rw -> super.update(rw), walk, + getRefDatabase()); + } + + @Override + public Result delete() throws IOException { + return invalidateSnapshotOnError(() -> super.delete(), + getRefDatabase()); + } + + @Override + public Result delete(RevWalk walk) throws IOException { + return invalidateSnapshotOnError(rw -> super.delete(rw), walk, + getRefDatabase()); + } + + @Override + public Result link(String target) throws IOException { + return invalidateSnapshotOnError(t -> super.link(t), target, + getRefDatabase()); + } + } + + private static class SnapshotRefDirectoryRename extends RefDirectoryRename { + SnapshotRefDirectoryRename(RefDirectoryUpdate src, + RefDirectoryUpdate dst) { + super(src, dst); + } + + @Override + public RefUpdate.Result rename() throws IOException { + return invalidateSnapshotOnError(() -> super.rename(), + getRefDirectory()); + } + } + + private static class SnapshotPackedBatchRefUpdate + extends PackedBatchRefUpdate { + SnapshotPackedBatchRefUpdate(RefDirectory refdb) { + super(refdb); + } + + SnapshotPackedBatchRefUpdate(RefDirectory refdb, + boolean shouldLockLooseRefs) { + super(refdb, shouldLockLooseRefs); + } + + @Override + public void execute(RevWalk walk, ProgressMonitor monitor, + List<String> options) throws IOException { + invalidateSnapshotOnError((rw, m, o) -> super.execute(rw, m, o), + walk, monitor, options, getRefDatabase()); + } + + @Override + public void execute(RevWalk walk, ProgressMonitor monitor) + throws IOException { + invalidateSnapshotOnError((rw, m, a3) -> super.execute(rw, m), walk, + monitor, null, getRefDatabase()); + } + } +} diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/lib/BatchRefUpdate.java b/org.eclipse.jgit/src/org/eclipse/jgit/lib/BatchRefUpdate.java index e2bebfefdb..d2367cc3d5 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/lib/BatchRefUpdate.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/lib/BatchRefUpdate.java @@ -521,6 +521,16 @@ public class BatchRefUpdate { monitor.endTask(); } + /** + * Get the ref database associated with this update. + * + * @return the ref database. + * @since 6.6 + */ + protected RefDatabase getRefDatabase() { + return refdb; + } + private static boolean isMissing(RevWalk walk, ObjectId id) throws IOException { if (id.equals(ObjectId.zeroId())) { diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/patch/PatchApplier.java b/org.eclipse.jgit/src/org/eclipse/jgit/patch/PatchApplier.java index 98a2804ee4..da698d6bf6 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/patch/PatchApplier.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/patch/PatchApplier.java @@ -9,6 +9,11 @@ */ package org.eclipse.jgit.patch; +import static org.eclipse.jgit.diff.DiffEntry.ChangeType.ADD; +import static org.eclipse.jgit.diff.DiffEntry.ChangeType.COPY; +import static org.eclipse.jgit.diff.DiffEntry.ChangeType.DELETE; +import static org.eclipse.jgit.diff.DiffEntry.ChangeType.MODIFY; +import static org.eclipse.jgit.diff.DiffEntry.ChangeType.RENAME; import static org.eclipse.jgit.lib.Constants.OBJ_BLOB; import java.io.ByteArrayInputStream; @@ -33,7 +38,6 @@ import java.util.stream.Collectors; import java.util.zip.InflaterInputStream; import org.eclipse.jgit.annotations.Nullable; import org.eclipse.jgit.api.errors.FilterFailedException; -import org.eclipse.jgit.api.errors.PatchApplyException; import org.eclipse.jgit.api.errors.PatchFormatException; import org.eclipse.jgit.attributes.Attribute; import org.eclipse.jgit.attributes.Attributes; @@ -134,11 +138,8 @@ public class PatchApplier { * ID of the tree to apply the patch in * @param oi * to be used for modifying objects - * @throws IOException - * in case of I/O errors */ - public PatchApplier(Repository repo, RevTree beforeTree, ObjectInserter oi) - throws IOException { + public PatchApplier(Repository repo, RevTree beforeTree, ObjectInserter oi) { this.repo = repo; this.beforeTree = beforeTree; inserter = oi; @@ -147,16 +148,48 @@ public class PatchApplier { /** * A wrapper for returning both the applied tree ID and the applied files - * list. + * list, as well as file specific errors. * * @since 6.3 */ public static class Result { + /** + * A wrapper for a patch applying error that affects a given file. + * + * @since 6.6 + */ + public static class Error { + + private String msg; + private String oldFileName; + private @Nullable HunkHeader hh; + + private Error(String msg, String oldFileName, + @Nullable HunkHeader hh) { + this.msg = msg; + this.oldFileName = oldFileName; + this.hh = hh; + } + + @Override + public String toString() { + if (hh != null) { + return MessageFormat.format(JGitText.get().patchApplyErrorWithHunk, + oldFileName, hh, msg); + } + return MessageFormat.format(JGitText.get().patchApplyErrorWithoutHunk, + oldFileName, msg); + } + + } + private ObjectId treeId; private List<String> paths; + private List<Error> errors = new ArrayList<>(); + /** * @return List of modified paths. */ @@ -170,6 +203,19 @@ public class PatchApplier { public ObjectId getTreeId() { return treeId; } + + /** + * @return Errors occurred while applying the patch. + * + * @since 6.6 + */ + public List<Error> getErrors() { + return errors; + } + + private void addError(String msg,String oldFileName, @Nullable HunkHeader hh) { + errors.add(new Error(msg, oldFileName, hh)); + } } /** @@ -180,12 +226,13 @@ public class PatchApplier { * @return the result of the patch * @throws PatchFormatException * if the patch cannot be parsed - * @throws PatchApplyException - * if the patch cannot be applied + * @throws IOException + * if the patch read fails + * @deprecated use {@link #applyPatch(Patch)} instead */ + @Deprecated public Result applyPatch(InputStream patchInput) - throws PatchFormatException, PatchApplyException { - Result result = new Result(); + throws PatchFormatException, IOException { Patch p = new Patch(); try (InputStream inStream = patchInput) { p.parse(inStream); @@ -193,105 +240,103 @@ public class PatchApplier { if (!p.getErrors().isEmpty()) { throw new PatchFormatException(p.getErrors()); } + } + return applyPatch(p); + } - DirCache dirCache = inCore() ? DirCache.read(reader, beforeTree) - : repo.lockDirCache(); - - DirCacheBuilder dirCacheBuilder = dirCache.builder(); - Set<String> modifiedPaths = new HashSet<>(); - for (FileHeader fh : p.getFiles()) { - ChangeType type = fh.getChangeType(); - switch (type) { - case ADD: { - File f = getFile(fh.getNewPath()); - if (f != null) { - try { - FileUtils.mkdirs(f.getParentFile(), true); - FileUtils.createNewFile(f); - } catch (IOException e) { - throw new PatchApplyException(MessageFormat.format( - JGitText.get().createNewFileFailed, f), e); - } - } - apply(fh.getNewPath(), dirCache, dirCacheBuilder, f, fh); + /** + * Applies the given patch + * + * @param p + * the patch to apply. + * @return the result of the patch + * @throws IOException + * @since 6.6 + */ + public Result applyPatch(Patch p) throws IOException { + Result result = new Result(); + DirCache dirCache = inCore() ? DirCache.read(reader, beforeTree) + : repo.lockDirCache(); + + DirCacheBuilder dirCacheBuilder = dirCache.builder(); + Set<String> modifiedPaths = new HashSet<>(); + for (FileHeader fh : p.getFiles()) { + ChangeType type = fh.getChangeType(); + File src = getFile(fh.getOldPath()); + File dest = getFile(fh.getNewPath()); + if (!verifyExistence(fh, src, dest, result)) { + continue; + } + switch (type) { + case ADD: { + if (dest != null) { + FileUtils.mkdirs(dest.getParentFile(), true); + FileUtils.createNewFile(dest); } - break; - case MODIFY: - apply(fh.getOldPath(), dirCache, dirCacheBuilder, - getFile(fh.getOldPath()), fh); - break; - case DELETE: - if (!inCore()) { - File old = getFile(fh.getOldPath()); - if (!old.delete()) - throw new PatchApplyException(MessageFormat.format( - JGitText.get().cannotDeleteFile, old)); - } - break; - case RENAME: { - File src = getFile(fh.getOldPath()); - File dest = getFile(fh.getNewPath()); - - if (!inCore()) { - /* - * this is odd: we rename the file on the FS, but - * apply() will write a fresh stream anyway, which will - * overwrite if there were hunks in the patch. - */ - try { - FileUtils.mkdirs(dest.getParentFile(), true); - FileUtils.rename(src, dest, - StandardCopyOption.ATOMIC_MOVE); - } catch (IOException e) { - throw new PatchApplyException(MessageFormat.format( - JGitText.get().renameFileFailed, src, dest), - e); - } - } - String pathWithOriginalContent = inCore() ? - fh.getOldPath() : fh.getNewPath(); - apply(pathWithOriginalContent, dirCache, dirCacheBuilder, dest, fh); - break; + apply(fh.getNewPath(), dirCache, dirCacheBuilder, dest, fh, result); + } + break; + case MODIFY: { + apply(fh.getOldPath(), dirCache, dirCacheBuilder, src, fh, result); + break; + } + case DELETE: { + if (!inCore()) { + if (!src.delete()) + throw new IOException(MessageFormat.format( + JGitText.get().cannotDeleteFile, src)); } - case COPY: { - File dest = getFile(fh.getNewPath()); - if (!inCore()) { - File src = getFile(fh.getOldPath()); - FileUtils.mkdirs(dest.getParentFile(), true); - Files.copy(src.toPath(), dest.toPath()); - } - apply(fh.getOldPath(), dirCache, dirCacheBuilder, dest, fh); - break; + break; + } + case RENAME: { + if (!inCore()) { + /* + * this is odd: we rename the file on the FS, but + * apply() will write a fresh stream anyway, which will + * overwrite if there were hunks in the patch. + */ + FileUtils.mkdirs(dest.getParentFile(), true); + FileUtils.rename(src, dest, + StandardCopyOption.ATOMIC_MOVE); } + String pathWithOriginalContent = inCore() ? + fh.getOldPath() : fh.getNewPath(); + apply(pathWithOriginalContent, dirCache, dirCacheBuilder, dest, fh, result); + break; + } + case COPY: { + if (!inCore()) { + FileUtils.mkdirs(dest.getParentFile(), true); + Files.copy(src.toPath(), dest.toPath()); } - if (fh.getChangeType() != ChangeType.DELETE) - modifiedPaths.add(fh.getNewPath()); - if (fh.getChangeType() != ChangeType.COPY - && fh.getChangeType() != ChangeType.ADD) - modifiedPaths.add(fh.getOldPath()); + apply(fh.getOldPath(), dirCache, dirCacheBuilder, dest, fh, result); + break; } - - // We processed the patch. Now add things that weren't changed. - for (int i = 0; i < dirCache.getEntryCount(); i++) { - DirCacheEntry dce = dirCache.getEntry(i); - if (!modifiedPaths.contains(dce.getPathString()) - || dce.getStage() != DirCacheEntry.STAGE_0) - dirCacheBuilder.add(dce); } + if (fh.getChangeType() != DELETE) + modifiedPaths.add(fh.getNewPath()); + if (fh.getChangeType() != COPY + && fh.getChangeType() != ADD) + modifiedPaths.add(fh.getOldPath()); + } - if (inCore()) - dirCacheBuilder.finish(); - else if (!dirCacheBuilder.commit()) { - throw new IndexWriteException(); - } + // We processed the patch. Now add things that weren't changed. + for (int i = 0; i < dirCache.getEntryCount(); i++) { + DirCacheEntry dce = dirCache.getEntry(i); + if (!modifiedPaths.contains(dce.getPathString()) + || dce.getStage() != DirCacheEntry.STAGE_0) + dirCacheBuilder.add(dce); + } - result.treeId = dirCache.writeTree(inserter); - result.paths = modifiedPaths.stream().sorted() - .collect(Collectors.toList()); - } catch (IOException e) { - throw new PatchApplyException(MessageFormat.format( - JGitText.get().patchApplyException, e.getMessage()), e); + if (inCore()) + dirCacheBuilder.finish(); + else if (!dirCacheBuilder.commit()) { + throw new IndexWriteException(); } + + result.treeId = dirCache.writeTree(inserter); + result.paths = modifiedPaths.stream().sorted() + .collect(Collectors.toList()); return result; } @@ -302,34 +347,61 @@ public class PatchApplier { /* returns null if the path is not found. */ @Nullable private TreeWalk getTreeWalkForFile(String path, DirCache cache) - throws PatchApplyException { - try { - if (inCore()) { - // Only this branch may return null. - // TODO: it would be nice if we could return a TreeWalk at EOF - // iso. null. - return TreeWalk.forPath(repo, path, beforeTree); - } - TreeWalk walk = new TreeWalk(repo); - - // Use a TreeWalk with a DirCacheIterator to pick up the correct - // clean/smudge filters. - int cacheTreeIdx = walk.addTree(new DirCacheIterator(cache)); - FileTreeIterator files = new FileTreeIterator(repo); - if (FILE_TREE_INDEX != walk.addTree(files)) - throw new IllegalStateException(); - - walk.setFilter(AndTreeFilter.create( - PathFilterGroup.createFromStrings(path), - new NotIgnoredFilter(FILE_TREE_INDEX))); - walk.setOperationType(OperationType.CHECKIN_OP); - walk.setRecursive(true); - files.setDirCacheIterator(walk, cacheTreeIdx); - return walk; - } catch (IOException e) { - throw new PatchApplyException(MessageFormat.format( - JGitText.get().patchApplyException, e.getMessage()), e); + throws IOException { + if (inCore()) { + // Only this branch may return null. + // TODO: it would be nice if we could return a TreeWalk at EOF + // iso. null. + return TreeWalk.forPath(repo, path, beforeTree); } + TreeWalk walk = new TreeWalk(repo); + + // Use a TreeWalk with a DirCacheIterator to pick up the correct + // clean/smudge filters. + int cacheTreeIdx = walk.addTree(new DirCacheIterator(cache)); + FileTreeIterator files = new FileTreeIterator(repo); + if (FILE_TREE_INDEX != walk.addTree(files)) + throw new IllegalStateException(); + + walk.setFilter(AndTreeFilter.create( + PathFilterGroup.createFromStrings(path), + new NotIgnoredFilter(FILE_TREE_INDEX))); + walk.setOperationType(OperationType.CHECKIN_OP); + walk.setRecursive(true); + files.setDirCacheIterator(walk, cacheTreeIdx); + return walk; + } + + private boolean fileExists(String path, @Nullable File f) + throws IOException { + if (f != null) { + return f.exists(); + } + return inCore() && TreeWalk.forPath(repo, path, beforeTree) != null; + } + + private boolean verifyExistence(FileHeader fh, File src, File dest, + Result result) throws IOException { + boolean isValid = true; + boolean srcShouldExist = List.of(MODIFY, DELETE, RENAME, COPY) + .contains(fh.getChangeType()); + boolean destShouldNotExist = List.of(ADD, RENAME, COPY) + .contains(fh.getChangeType()); + if (srcShouldExist != fileExists(fh.getOldPath(), src)) { + result.addError(MessageFormat.format(srcShouldExist + ? JGitText.get().applyPatchWithSourceOnNonExistentSource + : JGitText + .get().applyPatchWithoutSourceOnAlreadyExistingSource, + fh.getPatchType()), fh.getOldPath(), null); + isValid = false; + } + if (destShouldNotExist && fileExists(fh.getNewPath(), dest)) { + result.addError(MessageFormat.format(JGitText + .get().applyPatchWithCreationOverAlreadyExistingDestination, + fh.getPatchType()), fh.getNewPath(), null); + isValid = false; + } + return isValid; } private static final int FILE_TREE_INDEX = 1; @@ -348,135 +420,135 @@ public class PatchApplier { * The file to update with new contents. Null for inCore usage. * @param fh * The patch header. - * @throws PatchApplyException + * @param result + * The patch application result. + * @throws IOException */ private void apply(String pathWithOriginalContent, DirCache dirCache, - DirCacheBuilder dirCacheBuilder, @Nullable File f, FileHeader fh) - throws PatchApplyException { + DirCacheBuilder dirCacheBuilder, @Nullable File f, FileHeader fh, Result result) + throws IOException { if (PatchType.BINARY.equals(fh.getPatchType())) { // This patch type just says "something changed". We can't do // anything with that. // Maybe this should return an error code, though? return; } - try { - TreeWalk walk = getTreeWalkForFile(pathWithOriginalContent, dirCache); - boolean loadedFromTreeWalk = false; - // CR-LF handling is determined by whether the file or the patch - // have CR-LF line endings. - boolean convertCrLf = inCore() || needsCrLfConversion(f, fh); - EolStreamType streamType = convertCrLf ? EolStreamType.TEXT_CRLF + TreeWalk walk = getTreeWalkForFile(pathWithOriginalContent, dirCache); + boolean loadedFromTreeWalk = false; + // CR-LF handling is determined by whether the file or the patch + // have CR-LF line endings. + boolean convertCrLf = inCore() || needsCrLfConversion(f, fh); + EolStreamType streamType = convertCrLf ? EolStreamType.TEXT_CRLF + : EolStreamType.DIRECT; + String smudgeFilterCommand = null; + StreamSupplier fileStreamSupplier = null; + ObjectId fileId = ObjectId.zeroId(); + if (walk == null) { + // For new files with inCore()==true, TreeWalk.forPath can be + // null. Stay with defaults. + } else if (inCore()) { + fileId = walk.getObjectId(0); + ObjectLoader loader = LfsFactory.getInstance() + .applySmudgeFilter(repo, reader.open(fileId, OBJ_BLOB), + null); + byte[] data = loader.getBytes(); + convertCrLf = RawText.isCrLfText(data); + fileStreamSupplier = () -> new ByteArrayInputStream(data); + streamType = convertCrLf ? EolStreamType.TEXT_CRLF : EolStreamType.DIRECT; - String smudgeFilterCommand = null; - StreamSupplier fileStreamSupplier = null; - ObjectId fileId = ObjectId.zeroId(); - if (walk == null) { - // For new files with inCore()==true, TreeWalk.forPath can be - // null. Stay with defaults. - } else if (inCore()) { - fileId = walk.getObjectId(0); - ObjectLoader loader = LfsFactory.getInstance() - .applySmudgeFilter(repo, reader.open(fileId, OBJ_BLOB), - null); - byte[] data = loader.getBytes(); - convertCrLf = RawText.isCrLfText(data); - fileStreamSupplier = () -> new ByteArrayInputStream(data); - streamType = convertCrLf ? EolStreamType.TEXT_CRLF - : EolStreamType.DIRECT; - smudgeFilterCommand = walk - .getFilterCommand(Constants.ATTR_FILTER_TYPE_SMUDGE); + smudgeFilterCommand = walk + .getFilterCommand(Constants.ATTR_FILTER_TYPE_SMUDGE); + loadedFromTreeWalk = true; + } else if (walk.next()) { + // If the file on disk has no newline characters, + // convertCrLf will be false. In that case we want to honor the + // normal git settings. + streamType = convertCrLf ? EolStreamType.TEXT_CRLF + : walk.getEolStreamType(OperationType.CHECKOUT_OP); + smudgeFilterCommand = walk + .getFilterCommand(Constants.ATTR_FILTER_TYPE_SMUDGE); + FileTreeIterator file = walk.getTree(FILE_TREE_INDEX, + FileTreeIterator.class); + if (file != null) { + fileId = file.getEntryObjectId(); + fileStreamSupplier = file::openEntryStream; loadedFromTreeWalk = true; - } else if (walk.next()) { - // If the file on disk has no newline characters, - // convertCrLf will be false. In that case we want to honor the - // normal git settings. - streamType = convertCrLf ? EolStreamType.TEXT_CRLF - : walk.getEolStreamType(OperationType.CHECKOUT_OP); - smudgeFilterCommand = walk - .getFilterCommand(Constants.ATTR_FILTER_TYPE_SMUDGE); - FileTreeIterator file = walk.getTree(FILE_TREE_INDEX, - FileTreeIterator.class); - if (file != null) { - fileId = file.getEntryObjectId(); - fileStreamSupplier = file::openEntryStream; - loadedFromTreeWalk = true; - } else { - throw new PatchApplyException(MessageFormat.format( - JGitText.get().cannotReadFile, - pathWithOriginalContent)); - } + } else { + throw new IOException(MessageFormat.format( + JGitText.get().cannotReadFile, + pathWithOriginalContent)); } + } - if (fileStreamSupplier == null) - fileStreamSupplier = inCore() ? InputStream::nullInputStream - : () -> new FileInputStream(f); + if (fileStreamSupplier == null) + fileStreamSupplier = inCore() ? InputStream::nullInputStream + : () -> new FileInputStream(f); + + FileMode fileMode = fh.getNewMode() != null ? fh.getNewMode() + : FileMode.REGULAR_FILE; + ContentStreamLoader resultStreamLoader; + if (PatchType.GIT_BINARY.equals(fh.getPatchType())) { + // binary patches are processed in a streaming fashion. Some + // binary patches do random access on the input data, so we can't + // overwrite the file while we're streaming. + resultStreamLoader = applyBinary(pathWithOriginalContent, f, fh, + fileStreamSupplier, fileId, result); + } else { + String filterCommand = walk != null + ? walk.getFilterCommand( + Constants.ATTR_FILTER_TYPE_CLEAN) + : null; + RawText raw = getRawText(f, fileStreamSupplier, fileId, + pathWithOriginalContent, loadedFromTreeWalk, filterCommand, + convertCrLf); + resultStreamLoader = applyText(raw, fh, result); + } + if (resultStreamLoader == null || !result.getErrors().isEmpty()) { + return; + } - FileMode fileMode = fh.getNewMode() != null ? fh.getNewMode() - : FileMode.REGULAR_FILE; - ContentStreamLoader resultStreamLoader; - if (PatchType.GIT_BINARY.equals(fh.getPatchType())) { - // binary patches are processed in a streaming fashion. Some - // binary patches do random access on the input data, so we can't - // overwrite the file while we're streaming. - resultStreamLoader = applyBinary(pathWithOriginalContent, f, fh, - fileStreamSupplier, fileId); - } else { - String filterCommand = walk != null - ? walk.getFilterCommand( - Constants.ATTR_FILTER_TYPE_CLEAN) - : null; - RawText raw = getRawText(f, fileStreamSupplier, fileId, - pathWithOriginalContent, loadedFromTreeWalk, filterCommand, - convertCrLf); - resultStreamLoader = applyText(raw, fh); - } - - if (f != null) { - // Write to a buffer and copy to the file only if everything was - // fine. - TemporaryBuffer buffer = new TemporaryBuffer.LocalFile(null); - try { - CheckoutMetadata metadata = new CheckoutMetadata(streamType, - smudgeFilterCommand); - - try (TemporaryBuffer buf = buffer) { - DirCacheCheckout.getContent(repo, pathWithOriginalContent, - metadata, resultStreamLoader.supplier, workingTreeOptions, - buf); - } - try (InputStream bufIn = buffer.openInputStream()) { - Files.copy(bufIn, f.toPath(), - StandardCopyOption.REPLACE_EXISTING); - } - } finally { - buffer.destroy(); + if (f != null) { + // Write to a buffer and copy to the file only if everything was + // fine. + TemporaryBuffer buffer = new TemporaryBuffer.LocalFile(null); + try { + CheckoutMetadata metadata = new CheckoutMetadata(streamType, + smudgeFilterCommand); + + try (TemporaryBuffer buf = buffer) { + DirCacheCheckout.getContent(repo, pathWithOriginalContent, + metadata, resultStreamLoader.supplier, workingTreeOptions, + buf); } - - repo.getFS().setExecute(f, - fileMode == FileMode.EXECUTABLE_FILE); - } - - Instant lastModified = f == null ? null - : repo.getFS().lastModifiedInstant(f); - Attributes attributes = walk != null ? walk.getAttributes() - : new Attributes(); - - DirCacheEntry dce = insertToIndex( - resultStreamLoader.supplier.load(), - fh.getNewPath().getBytes(StandardCharsets.UTF_8), fileMode, - lastModified, resultStreamLoader.length, - attributes.get(Constants.ATTR_FILTER)); - dirCacheBuilder.add(dce); - if (PatchType.GIT_BINARY.equals(fh.getPatchType()) - && fh.getNewId() != null && fh.getNewId().isComplete() - && !fh.getNewId().toObjectId().equals(dce.getObjectId())) { - throw new PatchApplyException(MessageFormat.format( - JGitText.get().applyBinaryResultOidWrong, - pathWithOriginalContent)); + try (InputStream bufIn = buffer.openInputStream()) { + Files.copy(bufIn, f.toPath(), + StandardCopyOption.REPLACE_EXISTING); + } + } finally { + buffer.destroy(); } - } catch (IOException | UnsupportedOperationException e) { - throw new PatchApplyException(MessageFormat.format( - JGitText.get().patchApplyException, e.getMessage()), e); + + repo.getFS().setExecute(f, + fileMode == FileMode.EXECUTABLE_FILE); + } + + Instant lastModified = f == null ? null + : repo.getFS().lastModifiedInstant(f); + Attributes attributes = walk != null ? walk.getAttributes() + : new Attributes(); + + DirCacheEntry dce = insertToIndex( + resultStreamLoader.supplier.load(), + fh.getNewPath().getBytes(StandardCharsets.UTF_8), fileMode, + lastModified, resultStreamLoader.length, + attributes.get(Constants.ATTR_FILTER)); + dirCacheBuilder.add(dce); + if (PatchType.GIT_BINARY.equals(fh.getPatchType()) + && fh.getNewId() != null && fh.getNewId().isComplete() + && !fh.getNewId().toObjectId().equals(dce.getObjectId())) { + result.addError(MessageFormat.format( + JGitText.get().applyBinaryResultOidWrong, + pathWithOriginalContent), fh.getOldPath(), null); } } @@ -640,12 +712,12 @@ public class PatchApplier { } } - private void checkOid(ObjectId baseId, ObjectId id, ChangeType type, File f, - String path) throws PatchApplyException, IOException { + private boolean checkOid(ObjectId baseId, ObjectId id, ChangeType type, File f, + String path, Result result) throws IOException { boolean hashOk = false; if (id != null) { hashOk = baseId.equals(id); - if (!hashOk && ChangeType.ADD.equals(type) + if (!hashOk && ADD.equals(type) && ObjectId.zeroId().equals(baseId)) { // We create a new file. The OID of an empty file is not the // zero id! @@ -660,9 +732,10 @@ public class PatchApplier { } } if (!hashOk) { - throw new PatchApplyException(MessageFormat - .format(JGitText.get().applyBinaryBaseOidWrong, path)); + result.addError(MessageFormat + .format(JGitText.get().applyBinaryBaseOidWrong, path), path, null); } + return hashOk; } private boolean inCore() { @@ -700,18 +773,19 @@ public class PatchApplier { * a supplier for the contents of the old file * @param id * SHA1 for the old content - * @return a loader for the new content. - * @throws PatchApplyException + * @param result + * The patch application result + * @return a loader for the new content, or null if invalid. * @throws IOException * @throws UnsupportedOperationException */ - private ContentStreamLoader applyBinary(String path, File f, FileHeader fh, - StreamSupplier inputSupplier, ObjectId id) - throws PatchApplyException, IOException, - UnsupportedOperationException { + private @Nullable ContentStreamLoader applyBinary(String path, File f, FileHeader fh, + StreamSupplier inputSupplier, ObjectId id, Result result) + throws UnsupportedOperationException, IOException { if (!fh.getOldId().isComplete() || !fh.getNewId().isComplete()) { - throw new PatchApplyException(MessageFormat - .format(JGitText.get().applyBinaryOidTooShort, path)); + result.addError(MessageFormat + .format(JGitText.get().applyBinaryOidTooShort, path), path, null); + return null; } BinaryHunk hunk = fh.getForwardBinaryHunk(); // A BinaryHunk has the start at the "literal" or "delta" token. Data @@ -723,8 +797,10 @@ public class PatchApplier { case LITERAL_DEFLATED: { // This just overwrites the file. We need to check the hash of // the base. - checkOid(fh.getOldId().toObjectId(), id, fh.getChangeType(), f, - path); + if (!checkOid(fh.getOldId().toObjectId(), id, fh.getChangeType(), f, + path, result)) { + return null; + } StreamSupplier supp = () -> new InflaterInputStream( new BinaryHunkInputStream(new ByteArrayInputStream( hunk.getBuffer(), start, length))); @@ -756,8 +832,8 @@ public class PatchApplier { } } - private ContentStreamLoader applyText(RawText rt, FileHeader fh) - throws IOException, PatchApplyException { + private @Nullable ContentStreamLoader applyText(RawText rt, FileHeader fh, Result result) + throws IOException { List<ByteBuffer> oldLines = new ArrayList<>(rt.size()); for (int i = 0; i < rt.size(); i++) { oldLines.add(rt.getRawString(i)); @@ -771,8 +847,8 @@ public class PatchApplier { for (HunkHeader hh : fh.getHunks()) { // We assume hunks to be ordered if (hh.getNewStartLine() <= lastHunkNewLine) { - throw new PatchApplyException(MessageFormat - .format(JGitText.get().patchApplyException, hh)); + result.addError(JGitText.get().applyTextPatchUnorderedHunks, fh.getOldPath(), hh); + return null; } lastHunkNewLine = hh.getNewStartLine(); @@ -793,8 +869,9 @@ public class PatchApplier { newLines.clear(); break; } - throw new PatchApplyException(MessageFormat - .format(JGitText.get().patchApplyException, hh)); + result.addError(JGitText.get().applyTextPatchSingleClearingHunk, + fh.getOldPath(), hh); + return null; } // Hunk lines as reported by the hunk may be off, so don't rely on // them. @@ -805,8 +882,9 @@ public class PatchApplier { lineNumberShift = 0; } if (applyAt < afterLastHunk) { - throw new PatchApplyException(MessageFormat - .format(JGitText.get().patchApplyException, hh)); + result.addError(JGitText.get().applyTextPatchUnorderedHunkApplications, + fh.getOldPath(), hh); + return null; } boolean applies = false; int oldLinesInHunk = hh.getLinesContext() @@ -844,8 +922,9 @@ public class PatchApplier { } } if (!applies) { - throw new PatchApplyException(MessageFormat - .format(JGitText.get().patchApplyException, hh)); + result.addError(JGitText.get().applyTextPatchCannotApplyHunk, + fh.getOldPath(), hh); + return null; } // Hunk applies at applyAt. Apply it, and update afterLastHunk and // lineNumberShift diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/RevWalk.java b/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/RevWalk.java index 9da7105566..3737c6b67b 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/RevWalk.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/RevWalk.java @@ -550,6 +550,12 @@ public class RevWalk implements Iterable<RevCommit>, AutoCloseable { reset(~freeFlags & APP_FLAGS); filter = RevFilter.ALL; treeFilter = TreeFilter.ALL; + + // Make sure commit is parsed from commit-graph + if ((needle.flags & PARSED) == 0) { + needle.parseHeaders(this); + } + int cutoff = needle.getGeneration(); for (Ref r : haystacks) { if (monitor.isCancelled()) { return result; @@ -565,6 +571,10 @@ public class RevWalk implements Iterable<RevCommit>, AutoCloseable { boolean commitFound = false; RevCommit next; while ((next = next()) != null) { + if (next.getGeneration() < cutoff) { + markUninteresting(next); + uninteresting.add(next); + } if (References.isSameObject(next, needle) || (next.flags & TEMP_MARK) != 0) { result.add(r); diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/AmazonS3.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/AmazonS3.java index 4fec5da78f..d482521747 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/AmazonS3.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/AmazonS3.java @@ -171,6 +171,9 @@ public class AmazonS3 { /** S3 Bucket Domain. */ private final String domain; + /** S3 Protocol, "https" or "http"; defaults to "http". */ + private final String protocol; + /** S3 Region. */ private final String region; @@ -183,6 +186,7 @@ public class AmazonS3 { String CRYPTO_ALG = "crypto.algorithm"; //$NON-NLS-1$ String CRYPTO_VER = "crypto.version"; //$NON-NLS-1$ String ACL = "acl"; //$NON-NLS-1$ + String PROTOCOL = "protocol"; //$NON-NLS-1$ String DOMAIN = "domain"; //$NON-NLS-1$ String REGION = "region"; //$NON-NLS-1$ String HTTP_RETRY = "httpclient.retry-max"; //$NON-NLS-1$ @@ -246,6 +250,8 @@ public class AmazonS3 { awsApiSignatureVersion)); } + protocol = props.getProperty(Keys.PROTOCOL, "http"); //$NON-NLS-1$ + domain = props.getProperty(Keys.DOMAIN, "s3.amazonaws.com"); //$NON-NLS-1$ publicKey = props.getProperty(Keys.ACCESS_KEY); @@ -590,7 +596,8 @@ public class AmazonS3 { final String key, final Map<String, String> args) throws IOException { final StringBuilder urlstr = new StringBuilder(); - urlstr.append("http://"); //$NON-NLS-1$ + urlstr.append(protocol); //$NON-NLS-1$ + urlstr.append("://"); //$NON-NLS-1$ urlstr.append(bucket); urlstr.append('.'); urlstr.append(domain); diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/BasePackFetchConnection.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/BasePackFetchConnection.java index be36d2b834..8909380176 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/BasePackFetchConnection.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/BasePackFetchConnection.java @@ -37,6 +37,7 @@ import java.util.HashSet; import java.util.LinkedHashSet; import java.util.List; import java.util.Set; +import java.util.stream.Collectors; import org.eclipse.jgit.errors.PackProtocolException; import org.eclipse.jgit.errors.RemoteRepositoryException; @@ -215,6 +216,8 @@ public abstract class BasePackFetchConnection extends BasePackConnection private boolean allowOfsDelta; + private boolean useNegotiationTip; + private boolean noDone; private boolean noProgress; @@ -259,9 +262,11 @@ public abstract class BasePackFetchConnection extends BasePackConnection final FetchConfig cfg = getFetchConfig(); allowOfsDelta = cfg.allowOfsDelta; maxHaves = cfg.maxHaves; + useNegotiationTip = cfg.useNegotiationTip; } else { allowOfsDelta = true; maxHaves = Integer.MAX_VALUE; + useNegotiationTip = false; } includeTags = transport.getTagOpt() != TagOpt.NO_TAGS; @@ -297,14 +302,35 @@ public abstract class BasePackFetchConnection extends BasePackConnection final int maxHaves; + final boolean useNegotiationTip; + FetchConfig(Config c) { allowOfsDelta = c.getBoolean("repack", "usedeltabaseoffset", true); //$NON-NLS-1$ //$NON-NLS-2$ maxHaves = c.getInt("fetch", "maxhaves", Integer.MAX_VALUE); //$NON-NLS-1$ //$NON-NLS-2$ + useNegotiationTip = c.getBoolean("fetch", "usenegotiationtip", //$NON-NLS-1$ //$NON-NLS-2$ + false); } FetchConfig(boolean allowOfsDelta, int maxHaves) { + this(allowOfsDelta, maxHaves, false); + } + + /** + * @param allowOfsDelta + * when true optimizes the pack size by deltafying base + * object + * @param maxHaves + * max haves to be sent per negotiation + * @param useNegotiationTip + * if true uses the wanted refs instead of all refs as source + * of the "have" list to send. + * @since 6.6 + */ + FetchConfig(boolean allowOfsDelta, int maxHaves, + boolean useNegotiationTip) { this.allowOfsDelta = allowOfsDelta; this.maxHaves = maxHaves; + this.useNegotiationTip = useNegotiationTip; } } @@ -384,7 +410,7 @@ public abstract class BasePackFetchConnection extends BasePackConnection noProgress = monitor == NullProgressMonitor.INSTANCE; markRefsAdvertised(); - markReachable(have, maxTimeWanted(want)); + markReachable(want, have, maxTimeWanted(want)); if (TransferConfig.ProtocolVersion.V2 .equals(getProtocolVersion())) { @@ -662,9 +688,17 @@ public abstract class BasePackFetchConnection extends BasePackConnection return maxTime; } - private void markReachable(Set<ObjectId> have, int maxTime) + private void markReachable(Collection<Ref> want, Set<ObjectId> have, + int maxTime) throws IOException { + Set<String> wantRefs = want.stream().map(Ref::getName) + .collect(Collectors.toSet()); + for (Ref r : local.getRefDatabase().getRefs()) { + if (useNegotiationTip && !wantRefs.contains(r.getName())) { + continue; + } + ObjectId id = r.getPeeledObjectId(); if (id == null) id = r.getObjectId(); diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/util/IntList.java b/org.eclipse.jgit/src/org/eclipse/jgit/util/IntList.java index de8777f592..cc4f0a46fe 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/util/IntList.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/util/IntList.java @@ -37,6 +37,24 @@ public class IntList { } /** + * Create a list initialized with the values of the given range. + * + * @param start + * the beginning of the range, inclusive + * @param end + * the end of the range, exclusive + * @return the list initialized with the given range + * @since 6.6 + */ + public static IntList filledWithRange(int start, int end) { + IntList list = new IntList(end - start); + for (int val = start; val < end; val++) { + list.add(val); + } + return list; + } + + /** * Get number of entries in this list. * * @return number of entries in this list. @@ -126,6 +144,60 @@ public class IntList { add(val); } + /** + * Sort the entries of the list in-place, according to the comparator. + * + * @param comparator + * provides the comparison values for sorting the entries + * @since 6.6 + */ + public void sort(IntComparator comparator) { + quickSort(0, count - 1, comparator); + } + + /** + * Quick sort has average time complexity of O(n log n) and O(log n) space + * complexity (for recursion on the stack). + * <p> + * Implementation based on https://www.baeldung.com/java-quicksort. + * + * @param begin + * the index to begin partitioning at, inclusive + * @param end + * the index to end partitioning at, inclusive + * @param comparator + * provides the comparison values for sorting the entries + */ + private void quickSort(int begin, int end, IntComparator comparator) { + if (begin < end) { + int partitionIndex = partition(begin, end, comparator); + + quickSort(begin, partitionIndex - 1, comparator); + quickSort(partitionIndex + 1, end, comparator); + } + } + + private int partition(int begin, int end, IntComparator comparator) { + int pivot = entries[end]; + int writeSmallerIdx = (begin - 1); + + for (int findSmallerIdx = begin; findSmallerIdx < end; findSmallerIdx++) { + if (comparator.compare(entries[findSmallerIdx], pivot) <= 0) { + writeSmallerIdx++; + + int biggerVal = entries[writeSmallerIdx]; + entries[writeSmallerIdx] = entries[findSmallerIdx]; + entries[findSmallerIdx] = biggerVal; + } + } + + int pivotIdx = writeSmallerIdx + 1; + entries[end] = entries[pivotIdx]; + entries[pivotIdx] = pivot; + + return pivotIdx; + } + private void grow() { final int[] n = new int[(entries.length + 16) * 3 / 2]; System.arraycopy(entries, 0, n, 0, count); @@ -145,4 +217,22 @@ public class IntList { r.append(']'); return r.toString(); } + + /** + * A comparator of primitive ints. + */ + public interface IntComparator { + + /** + * Compares the two int arguments for order. + * + * @param first + * the first int to compare + * @param second + * the second int to compare + * @return a negative number if first < second, 0 if first == second, or + * a positive number if first > second + */ + int compare(int first, int second); + } } @@ -18,7 +18,7 @@ <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> <packaging>pom</packaging> - <version>6.5.1-SNAPSHOT</version> + <version>6.6.0-SNAPSHOT</version> <name>JGit - Parent</name> <url>${jgit-url}</url> @@ -150,7 +150,7 @@ <java.version>11</java.version> <bundle-manifest>${project.build.directory}/META-INF/MANIFEST.MF</bundle-manifest> - <jgit-last-release-version>6.4.0.202211300538-r</jgit-last-release-version> + <jgit-last-release-version>6.5.0.202303070854-r</jgit-last-release-version> <ant-version>1.10.12</ant-version> <apache-sshd-version>2.9.2</apache-sshd-version> <jsch-version>0.1.55</jsch-version> @@ -282,7 +282,6 @@ <forkCount>${test-fork-count}</forkCount> <reuseForks>true</reuseForks> <argLine>@{argLine}</argLine> - <rerunFailingTestsCount>3</rerunFailingTestsCount> </configuration> </plugin> @@ -763,7 +762,7 @@ <dependency> <groupId>org.bouncycastle</groupId> <artifactId>bcpg-jdk18on</artifactId> - <version>${bouncycastle-version}</version> + <version>1.72.2</version> </dependency> <dependency> |