Use of the Egit plugin under eclipse

Source: Internet
Author: User

It's been a long time since you've been in touch with Git, but the company you run into has always been using SVN and refusing to switch to git for a variety of reasons. Having changed jobs this year and taking the opportunity to build a new framework and project for the company, Git was finally used on the official project. Git's server uses https://gitee.com/directly, and saves itself from building and maintaining it. Git's client tool eclipse defaults to provide the Egit plug-in, just start with a bit awkward, feel inferior to command line, but groped also used, feel very good, encountered a few small problems organized as follows:

Case 1: "Rejected-non-fast-forwad" error in the Push times: Resolution: The discovery code was not committed to a remote git server, perhaps the last commit was committed only to a local git server, then through the "push To upstream "from the local git repository to the remote.

Case 2: In Pull, there is a conflict: The resolution process: go to the Synchronize view, see where the conflict occurred, resolve the conflict and find the conflict file in the Synchronize view or the presence of the pull, the pull will still report a conflict. This is because the first pull, the code in the project changes a file has not been committed (the local Git repository is not committed), and the file was also changed by others and was first submitted to the remote Git repository, pull, Because the local git repository does not conflict with the remote Git repository, the local repository has been updated by pull. This conflict is only a conflict between the project code and the local git repository, so after resolving the conflict on the sync view, commit to the local repository and then pull again.

Anyway, if you have a problem, think about it now. "Staging Area", "Workspace Project", "Local Git Repository", "Remote Git repository" situation, as long as the brain clear, the problem is not difficult to solve.

Use of the Egit plugin under eclipse

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.