Configuring Eclipse E-Git

Discussion in 'Wiki Discussion' started by jflory7, May 8, 2015.

  1. jflory7

    jflory7 Retired Moderator
    Retired Benefactor

    Configuring Eclipse E-Git

    This article needs clean-up.
    This article is either unclear, poorly worded, or a bit disorganized. Help improve our wiki by clarifying this article!!!​

    Configuring E-Git for Eclipse

    Step by step details on how to setup E-Git for Eclipse.

    1. Window (Eclipse if Mac) > Preferences
    2. General > Network Connections > SSH2 > Key Management
    3. Generate DSA Key
    4. Give it a comment (your server name or username, anything is fine)
    5. Select all text and copy
    6. Save Private Key & Apply
    7. Team > Git > Configuration
    8. Add Entry
    9. OK & Apply & OK
    10. Travel to SSH keys on Github
    11. Add SSH key
    12. Paste in Key
    13. Copy comment from step 5 (very end of key) and paste in Title & Add key
    14. Travel to New Repository on Github
    15. Give it a name
    16. Create repository
    17. Under Quick Setup, copy the git url (looks like: [email protected]:<username>/<repository>.git)
    18. Open Eclipse
    19. Create new Java Project (if you have an existing project, skip to step 22)
    20. Create new package (ex.: com.github.example)
    21. Create new class in package from step 20, name it anything
    22. Right click project, Team > Share Project
    23. Git & Next
    24. Activate checkbox for Use or create repository in parent folder of project
    25. Select project in list
    26. Create Repository & Finish
    27. Window > Show View > Other
    28. Git > Git Repositories & OK
    29. Expand your project in the Git Repositories
    30. Right click Remotes & Create Remote
    31. Enter Remote name (identical to project name) & OK
    32. Change & Finish & Save
    33. Right click project in Package Explorer & Team > Commit
    34. Select All & Give a commit message called "Initial commit" & Commit
    35. Right click project in Package Explorer & Team > Push Branch & Next & Finish
    36. Go back to Git Repositories and expand Remotes and then your project name
    37. Right click one of the cylinders & Configure & Advanced
    38. Source ref: master [branch] (Destination ref should auto populate with: refs/heads/master)
    39. Add Spec
    40. Check off Force Update & Finish & Save
    41. Repeat steps 37 through 40 for the other cylinder

    Assuming nothing went wrong, your project is now configured for version control. You can now make changes to your code and commit & push it (step 33, different button) and an update can be requested by another user in almost real-time.

    Each user after the original setup will need to import a git project using similar steps from above, but I have never done that. Good luck.
  2. jflory7

    jflory7 Retired Moderator
    Retired Benefactor

    I found this article sitting orphaned in the wiki section, and I saw that it had a decent number of hits!

    As a result, I think capitalized on the SEO for this wiki article is a great idea so we can create a more comprehensive overview of how to do this for anyone who is getting started with programming in Spigot. If I used Eclipse, I would update it myself, but I don't think I'm the best candidate for the job.

    I think even someone going through and adding some screenshots with a more clearly organized manner would help a good bit, just like this article and this article.
  3. I wrote this article a while back for some users and turned it into the wiki page. If you guys want some images, I'd be more than happy to get some going to help with the less understandable portions of the instructions.
    • Like Like x 1
  4. jflory7

    jflory7 Retired Moderator
    Retired Benefactor

    I think a rewrite might be very helpful, as this is definitely something I can see a lot of people finding useful to get going on their development projects. :)