command.setTimeout(timeout.toInteger());
.setProgressMonitor(PROGRESS_MONITOR) .setCredentialsProvider(user) .setTimeout(pullPushTimeoutSeconds) .call(); } catch (GitAPIException e) {
.setProgressMonitor(PROGRESS_MONITOR) .setCredentialsProvider(user) .setTimeout(pullPushTimeoutSeconds) .call(); } catch (GitAPIException e) {
fetch.setTimeout((int) TimeUnit.MINUTES.toSeconds(TIMEOUT));
.setTagOpt(tags ? TagOpt.FETCH_TAGS : TagOpt.NO_TAGS) .setRefSpecs(refspecs); if (timeout != null) fetch.setTimeout(timeout); fetch.call();
@Override protected void run() throws Exception { Git git = new Git(db); FetchCommand fetch = git.fetch(); if (fsck != null) fetch.setCheckFetchedObjects(fsck.booleanValue()); if (prune != null) fetch.setRemoveDeletedRefs(prune.booleanValue()); if (toget != null) fetch.setRefSpecs(toget); if (tags != null) { fetch.setTagOpt(tags.booleanValue() ? TagOpt.FETCH_TAGS : TagOpt.NO_TAGS); } if (0 <= timeout) fetch.setTimeout(timeout); fetch.setDryRun(dryRun); fetch.setRemote(remote); if (thin != null) fetch.setThin(thin.booleanValue()); if (quiet == null || !quiet.booleanValue()) fetch.setProgressMonitor(new TextProgressMonitor()); FetchResult result = fetch.call(); if (result.getTrackingRefUpdates().isEmpty()) return; showFetchResult(result); } }
try { GitHelpers.checkoutBranch(git, branch); FetchResult fetchResult = git.fetch().setTimeout(gitTimeout).setCredentialsProvider(credentialsProvider).setRemote(remoteRef).setRefSpecs(new RefSpec("refs/heads/" + branch)).call(); Ref fetchRef = fetchResult.getAdvertisedRef("refs/heads/" + branch); git.branchRename().setOldName(branch).setNewName(branch + "-tmp").call();
git.fetch().setTimeout(gitTimeout).setCredentialsProvider(credentialsProvider).setRemote(remoteRef).call(); } catch (GitAPIException | JGitInternalException ex) { lastException = ex;
git.fetch().setTimeout(timeoutInSeconds).setCredentialsProvider(credentialsProvider) .setTagOpt(TagOpt.FETCH_TAGS) .setRemote(remoteRef).call();
try { GitHelpers.checkoutBranch(git, branch); FetchResult fetchResult = git.fetch().setTimeout(gitTimeout).setCredentialsProvider(credentialsProvider).setRemote(remoteRef).setRefSpecs(new RefSpec("refs/heads/" + branch)).call(); Ref fetchRef = fetchResult.getAdvertisedRef("refs/heads/" + branch); git.branchRename().setOldName(branch).setNewName(branch + "-tmp").call();
.setRemoveDeletedRefs(true) .setTagOpt(TagOpt.NO_TAGS) .setTimeout(GIT_TIMEOUT_SECS) .call();
@Override public FetchResult fetch(final Git git, final String remote, final String refSpec, final int timeout, final boolean fsck, final boolean dryRun, final boolean thin, final boolean prune) throws GitAPIException { FetchCommand fetch = git.fetch(); fetch.setCheckFetchedObjects(fsck); fetch.setRemoveDeletedRefs(prune); if (refSpec != null) fetch.setRefSpecs(new RefSpec(refSpec)); if (timeout >= 0) fetch.setTimeout(timeout); fetch.setDryRun(dryRun); fetch.setRemote(remote); fetch.setThin(thin); fetch.setProgressMonitor(new TextProgressMonitor()); FetchResult result = fetch.call(); return result; }
.setRemoveDeletedRefs(true) .setTagOpt(TagOpt.NO_TAGS) .setTimeout(GIT_TIMEOUT_SECS) .call();
.setRemoveDeletedRefs(true) .setTagOpt(TagOpt.NO_TAGS) .setTimeout(GIT_TIMEOUT_SECS) .call();