How do EGit versions map to Git versions - eclipse

The Git Source Code Mirror on GitHub (https://github.com/git/git) says that the most recent version of Git is 2.7.4. I'm using EGit 3.5.2 on Spring Tool Suite (Eclipse Luna SR1), so that version number obviously doesn't correspond to a Git version. Is there any way to trace back what version of Git this version of EGit is based off of?
I checked here, but it only maps versions of EGit to versions of Eclipse...
https://wiki.eclipse.org/EGit/FAQ#What_is_Git.3F

As you noticed, EGit does not appear to be based on a particular version of Git. The EGit documentation has the following to say:
How compatible is EGit with Git?
Some, but not all configuration options/features in Git are available in EGit/JGit. Here is a summary, not yet complete describing some of these, including notable differences. Note that the set of EGit/JGit is not based off a particular Git version.
Practically speaking, as long as you are using the most recent version of Git, you should be OK. This is because Git itself should be backwards-compatible with whatever version of Git was concurrent with the particular release of EGit which you are using. But I would not recommend the other way around, e.g. using the first release of Git from many years ago with the latest EGit plugin.

There is no correlation between EGit and Git versions. EGit uses JGit, a pure Java implementation of the Git VCS, to access repositories. JGit versions do not follow a specific Git versions either. Though JGit is relatively on par with Git, some things are missing, for example git clone -- depth. Unfortunately, a detailed comparison does not exist

Related

Questions about egit and github/travis

i'm a beginner java developer, i need to use eclipse and i have some questions about eclipse/github/egit/jgit/travis.
I need to get the commits made on a repository in github. I found on the internet that this is possible with both jgit and egit and more in depth that egit uses jgit. My first question is: are jgit and egit functionally equivalent? (all i can do with egit i can do it with jgit and vice versa)?
To get the date of a commit with egit I have to write something like commit.getAuthor().getDate(), why does this work? That is, commit.getAuthor() returns an instance of the class CommitUser, why a method of the class CommitUser returns the commit date? shouldn't getDate() be a method of the class Commit?
My project must be loaded into a repository managed through SVN and on which I will have to use the tools travis and sonarcloud. My question is: how does the management of external jars added to the project take place when I use travis and sonarcloud? Will I get errors? How should I handle them?
JGit is a Java implementation of Git and used by EGit (= Eclipse IDE Git support) and other Java applications and frameworks, e.g. by Gerrit.
That's JGit, not EGit. A commit has two dates, the authored date (when it was committed) and the committed date (when it was pushed).
In a plain Java application JGit can be used as Maven dependency, the Eclipse IDE is not required to build your application.

Will installing Egit interfere with existing Git installation?

I have been working with Git from the command-line for a few weeks. I am now on a project that uses Eclipse as the IDE and EGit for the Git plugin. I am worried that by installing EGit I'm going to destroy any Git configs in my existing projects (that I've been maintaining/coding directly from a terminal).
If EGit could interfere, how so (and how can I avoid this)? If not, why?
No, it doesnt interfere. EGit only works within Eclipse and is independent from a command line Git installation. Regarding the configuration EGit of course reads your existing gitconfig. But if you use a recent Git version on the command line, there shouldn't be any differences in the config.
In fact you can keep using Git on the command line for committing, pushing etc. It doesn't matter if the project is configured for EGit in Eclipse.

Git-svn and Eclipse?

Is there a plugin for Eclipse for git-svn? I'm looking for a way to handle the SVN repo with Git (for fast branch switching etc.)
It does not look like there is a Git plugin for Eclipse that supports git-svn yet.
EGit appears to be the most active and popular Git plugin for Eclipse at the moment and it does not support git-svn, but there isn't anything stopping you from using EGit with Eclipse and interacting with git-svn via command line (or via tortoise git for example).
Eclipse bug 315264 is the EGit bug for supporting git-svn, and it looks like something that the maintainers of EGit are willing implement, but they have other priorities atm. So make sure you vote for this bug if you want the feature.
EGit is the only Git plugin for Eclipse at the moment. It doesn't support git-svn. But there is a way to make EGit work with your Subversion repository and this approach works well with any other Git client.
SubGit is the server-side solution that enables Git access to your Subversion repositories as well as Subversion access to Git repositories. You may refer to SubGit documenation for more details, but in general they are quite straightforward:
$ subgit configure --layout auto $SVN_URL $GIT_REPO
# Adjust $GIT_REPO/subgit/config
# to specify your branches, tags and other settings
# Adjust $GIT_REPO/subgit/authors.txt
# to introduce svn author names to their git counterparts
# Adjust $GIT_REPO/subgit/passwd
# in case you have no SVN credentials cached on your machine
$ subgit install $GIT_REPO
$ ... translating ... a little git is gonna born right here ...
$ TRANSLATION SUCCESSFUL
After that:
You have Git repository at $GIT_REPO synchronized with SVN repository at $SVN_URL; this sync is reliably bi-directional, i.e. both SVN and Git repositories remain writable and SubGit takes care of changes from both sides.
SubGit has installed hooks into $GIT_REPO/hooks directory which are triggered on every git push to that repository.
SubGit polls SVN repository in order to fetch new revisions.
Please note that your teammates may use the same mirror for sending their changes to Subversion repository. In this case you should setup Git server, fortunately, SubGit supports virtually every Git server available at the moment:
Apache HTTP server with git-http-backend, GitLab, Gitosis, Gitolite: supported out of the box;
Atlassian Bitbucket Server: in this case you can use SVN Mirror add-on which is built on SubGit engine;
Gerrit: you'd need to install SubGit plugin for Gerrit in this case;
Disclaimer: I'm SubGit developer; SubGit is commercial software with free options for small teams, Open Source and Academic projects.
Although this question is 4 years old, I thought I would share my recently found workaround:
Open "External Tools Configurations" (right next to "Run
Configurations") and create a new "Program" configuration.
For the working directory, choose your project from the workspace.
Enter svn dcommit into the arguments textfield.
Duplicate the configuration and replace svn dcommit by svn rebase.
Now you can launch git svn dcommit and git svn rebase with two clicks.

Compatibility of EGit - or are there alternatives?

I'm developing with Eclipse and managing my repositories with git and gitorious. Until now, I used git on the command line. I've looked around for a way to integrate git into Eclipse and found EGit. This has also been asked on SO two years ago. But as EGit uses JGit, a git clone written in Java, I'm concerned about its compatibility with the original git.
I know that EGit is missing some (maybe a lot) of git's advanced features, so I would use EGit for daily basic uses like commits, checkouts, pulls and pushes, branching, etc, and use git for more advanced - but less frequent - tasks. Any experiences? I won't use EGit if there is any chance that my repos get broken just because git and EGit didn't agree on how to manage them!
Another question: Are there alternatives to EGit? I couldn't find any.
As one of the developers of EGit and JGit, all I can say is that the projects are still in beta (incubation in eclipse.org terms). We are evolving quickly and have managed to pump out a release every 3 months for the past year. We recently shipped 0.10.1 and are planning to push a 0.11 release at the end of February. Our goal is to ship a 1.0 for the major Eclipse Indigo release in June which would be usable by the whole Eclipse community. This is required because eclipse.org itself is moving to Git.
One of the best things you can do with EGit is to checkout the user guide which aims to help people use EGit in the way it was intended, See Eclipse Wiki
If you have any questions, you can always use our mailing list or bugzilla. More information can be found in our extensive contributor guide.
On a side note, SmartGit under the covers uses JGit to handle the operations. Gerrit the popular code review tool (used by the Android dev team and others) uses JGit under the covers too. JGit has ~1800 tests to ensure compatibility with Git and even has some developers that work on CGit too. In the beginning we had a bit of trouble with compatibility but that is no longer the case with our extensive test suite. The project has developers from SAP, Google, Red Hat and other companies.
I know you are looking for a way to integrate into Eclipse, but in my experience trying to do this does not work. Even if EGit is perfectly compatible with your Git repo's it is still buggy as hell. I use NetBeans now which has Mercurial built in and optional Git plugins, they are still useless!
If you want a nice visual way to work with Git then try SmartGit or Tower. I have used both a little and heard great things about them, but mainly stick to CLI + GitX.

Checking out a project on github with the Eclipse CVS client?

I am playing with my eclipse cvs functionality (on my windows box), is there a way to check out a project hosted on github?
Anyone shows me a pointer? Thanks,
Not with the CVS client. You need to install git for Windows or a git plugin for Eclipse.
CVS and git are two different source code version control systems. Other popular choices are Subversion or Mercurial. You have to use different clients or Eclipse plugins for each of them.
Use EGit, which provides Git support as part of Eclipse and is available in both the latest Helios builds as well as the upcoming Indigo release.