Skip to content

Commit c6c3e08

Browse files
authored
Merge pull request #8892 from mbien/jgit740
Update jgit from 7.2.0 to 7.6.0
2 parents ad4ae12 + d4cd514 commit c6c3e08

25 files changed

Lines changed: 39 additions & 39 deletions

File tree

ide/libs.git/src/org/netbeans/libs/git/jgit/commands/GitCommand.java

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,6 @@
1919

2020
package org.netbeans.libs.git.jgit.commands;
2121

22-
import java.security.AccessController;
23-
import java.security.PrivilegedActionException;
24-
import java.security.PrivilegedExceptionAction;
2522
import java.text.MessageFormat;
2623
import org.eclipse.jgit.lib.Repository;
2724
import org.netbeans.libs.git.GitException;
@@ -49,17 +46,7 @@ public final void execute () throws GitException {
4946
if (prepareCommand()) {
5047
try {
5148
monitor.started(getCommandDescription());
52-
try {
53-
AccessController.doPrivileged(new PrivilegedExceptionAction<Void>() {
54-
@Override
55-
public Void run () throws GitException {
56-
GitCommand.this.run();
57-
return null;
58-
}
59-
});
60-
} catch (PrivilegedActionException e) {
61-
throw (GitException) e.getException();
62-
}
49+
run();
6350
} catch (RuntimeException ex) {
6451
if (ex.getMessage() != null && ex.getMessage().contains("Unknown repository format")) { //NOI18N
6552
throw new GitException("It seems the config file for repository at [" + repository.getWorkTree() + "] is corrupted.\nEnsure it's valid.", ex); //NOI18N

ide/libs.git/src/org/netbeans/libs/git/jgit/commands/LogCommand.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,9 @@ public class LogCommand extends GitCommand {
8181
private final boolean fetchBranchInfo;
8282
private static final Logger LOG = Logger.getLogger(LogCommand.class.getName());
8383

84+
/// see RevWalk.newFlag(); note: don't trust the doc! check RevWalk.RESERVED_FLAGS
85+
static final int MAX_REVWALK_FLAGS = 23;
86+
8487
public LogCommand (Repository repository, GitClassFactory gitFactory, SearchCriteria criteria,
8588
boolean fetchBranchInfo, ProgressMonitor monitor, RevisionInfoListener listener) {
8689
super(repository, gitFactory, monitor);
@@ -210,7 +213,7 @@ private void markBranchFlags (Map<String, GitBranch> allBranches, RevWalk walk,
210213
}
211214
} else {
212215
usedFlags.add(flagId);
213-
if (i <= 23) { // leave one spare flag for the run method, see RevWalk.newFlag()
216+
if (i <= MAX_REVWALK_FLAGS - 1) { // leave one spare flag for the run method
214217
i++;
215218
RevFlag flag = walk.newFlag(flagId);
216219
List<GitBranch> branches = new ArrayList<>(allBranches.size());

ide/libs.git/test/unit/src/org/netbeans/libs/git/jgit/commands/LogTest.java

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121

2222
import java.io.File;
2323
import java.io.IOException;
24+
import java.lang.reflect.Field;
2425
import java.util.Date;
2526
import java.util.Map;
2627
import org.eclipse.jgit.api.Git;
@@ -59,6 +60,15 @@ protected void setUp() throws Exception {
5960
repository = getRepository(getLocalGitRepository());
6061
}
6162

63+
// doc promises 24, but the actual number was observed to be lower since 7.5
64+
// this is a tripwire test to detect changes
65+
public void testMaxApplicationFlagCount() throws Exception {
66+
Field field = RevWalk.class.getDeclaredField("RESERVED_FLAGS");
67+
field.setAccessible(true);
68+
int available = 32 - (int) field.get(null);
69+
assertEquals(LogCommand.MAX_REVWALK_FLAGS, available); // if this fails, adjust the value
70+
}
71+
6272
public void testLogRevision () throws Exception {
6373
File f = new File(workDir, "testcat1");
6474
write(f, "initial content");

ide/o.eclipse.jgit.gpg.bc/external/binaries-list

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@
1414
# KIND, either express or implied. See the License for the
1515
# specific language governing permissions and limitations
1616
# under the License.
17-
F1A7C31962EEF791DDA4FF91043DF531F06F5F04 org.eclipse.jgit:org.eclipse.jgit.gpg.bc:7.2.1.202505142326-r
17+
FD8967B5C67D63796C4665116AFA85F3D0A4D130 org.eclipse.jgit:org.eclipse.jgit.gpg.bc:7.6.0.202603022253-r

ide/o.eclipse.jgit.gpg.bc/external/org.eclipse.jgit.gpg.bc-7.2.1.202505142326-r-license.txt renamed to ide/o.eclipse.jgit.gpg.bc/external/org.eclipse.jgit.gpg.bc-7.6.0.202603022253-r-license.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Name: JGit Library
22
Origin: Eclipse
3-
Version: 7.2.1.202505142326-r
3+
Version: 7.6.0.202603022253-r
44
Description: Integration library for Git client
55
License: EDL-1.0-jgit
66
URL: http://www.eclipse.org/jgit/download/

ide/o.eclipse.jgit.gpg.bc/nbproject/project.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,4 @@
1717

1818
is.autoload=true
1919

20-
release.external/org.eclipse.jgit.gpg.bc-7.2.1.202505142326-r.jar=modules/org-eclipse-jgit-gpg-bc.jar
20+
release.external/org.eclipse.jgit.gpg.bc-7.6.0.202603022253-r.jar=modules/org-eclipse-jgit-gpg-bc.jar

ide/o.eclipse.jgit.gpg.bc/nbproject/project.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@
6565
<public-packages/>
6666
<class-path-extension>
6767
<runtime-relative-path>org-eclipse-jgit-gpg-bc.jar</runtime-relative-path>
68-
<binary-origin>external/org.eclipse.jgit.gpg.bc-7.2.1.202505142326-r.jar</binary-origin>
68+
<binary-origin>external/org.eclipse.jgit.gpg.bc-7.6.0.202603022253-r.jar</binary-origin>
6969
</class-path-extension>
7070
</data>
7171
</configuration>

ide/o.eclipse.jgit.lfs/external/binaries-list

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@
1414
# KIND, either express or implied. See the License for the
1515
# specific language governing permissions and limitations
1616
# under the License.
17-
C599E6652B31273A8668982082916E1AC1C5FEC6 org.eclipse.jgit:org.eclipse.jgit.lfs:7.2.1.202505142326-r
17+
EA88518D6722FA4B3A7BBA8FE8233BC2B22B02C9 org.eclipse.jgit:org.eclipse.jgit.lfs:7.6.0.202603022253-r

ide/o.eclipse.jgit.lfs/external/org.eclipse.jgit.lfs-7.2.1.202505142326-r-license.txt renamed to ide/o.eclipse.jgit.lfs/external/org.eclipse.jgit.lfs-7.6.0.202603022253-r-license.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Name: JGit Library
22
Origin: Eclipse
3-
Version: 7.2.1.202505142326-r
3+
Version: 7.6.0.202603022253-r
44
Description: Integration library for Git client
55
License: EDL-1.0-jgit
66
URL: http://www.eclipse.org/jgit/download/

ide/o.eclipse.jgit.lfs/nbproject/project.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,4 @@
1717

1818
is.autoload=true
1919

20-
release.external/org.eclipse.jgit.lfs-7.2.1.202505142326-r.jar=modules/org-eclipse-jgit-lfs.jar
20+
release.external/org.eclipse.jgit.lfs-7.6.0.202603022253-r.jar=modules/org-eclipse-jgit-lfs.jar

0 commit comments

Comments
 (0)