Skip to main content



      Home
Home » Eclipse Projects » EGit / JGit » jGit FetchCommand
jGit FetchCommand [message #912905] Fri, 14 September 2012 07:34 Go to next message
Eclipse UserFriend
Hi

I understand the concept of Git fetch. I would like to fetch objects through the FetchCommand class.

I have a main repository. For example: C:\jGit\.git.
I have cloned this repository. For example C:\jGitClone\.git.

Using the jGit API I have a Git class:

Git git = new Git(repository); // this is the main repository.

How would I set the cloned repository so when the fetch is called it knows to fetch into the cloned repository.

I have looked on some websites but still stuck.

[Updated on: Fri, 14 September 2012 07:35] by Moderator

Re: jGit FetchCommand [message #925287 is a reply to message #912905] Thu, 27 September 2012 11:18 Go to previous message
Eclipse UserFriend
Have a look at EGit's FetchOperation [1] or JGit's FetchCommandTest [2].

[1] https://git.eclipse.org/c/egit/egit.git/tree/org.eclipse.egit.core/src/org/eclipse/egit/core/op/FetchOperation.java
[2] https://git.eclipse.org/c/jgit/jgit.git/tree/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/FetchCommandTest.java
Previous Topic:Use EGit For PHP Deployment (like FTP client)
Next Topic:History list of commits invisible
Goto Forum:
  


Current Time: Wed Jul 23 12:17:41 EDT 2025

Powered by FUDForum. Page generated in 0.03751 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top