Blogs
Posted: 11/03/2010 at 3:19 PM by Marco Williams
So I am mostly posting this blog because, every bit of documentation out there leave one thing or another out and I found myself searching the web for what is missing. In this blog you will find the answers to properly setting up a project in Eclipse and then Publishing that project to github.com. I will also cover if you already have a project that is preexisting and you want to publish it to a new github repository. In addition I will cover how to import a project from a github repository.
Unfortunately I do not have time to write out every little detail. So there are some things you should know how to do prior to reading this tutorial.
Okay, Let's begin.
Install the Eclipse plug-in.
The source URL can is - http://download.eclipse.org/egit/updates
You can view information about eGit @ http://www.eclipse.org/egit/
There are two options from their source URL. Personally, I don't know or understand which is which..so I installed both of them.. From what i do understand, the two are eGit & jGit .. eGit is suposed to have the GUI for eclipse.. I don't know what jGit is for.. But at this point.. i don't care.. install them both unless you know more about the differences.
Create your Key to authenticate with GitHub.
Go to the link below and follow the instructions there. They are pretty dead on and it will work.
http://help.github.com/msysgit-key-setup/
Once you have done the above.. This is the part that no one tells you!
The key is in the wrong place, yep it's stupid I know. The key is in the .ssh folder in your windows profile.
Mine was in C:\Users\Marco\.ssh and I'm on a windows 7 box. So you'll have to find yours if your on a different version of windows. Eclipse looks for the key in a different place. It looks for it in "ssh" not ".ssh" so you have to copy all the files from your .ssh folder to the ssh folder. The ssh folder is in the same location as your .ssh folder. It just does not have a "dot".
Now you are ready to begin using GitHub.
Part 1: New Project and put it to GitHub
Note: An existing project is the 2 - 9 steps..
Part 2: Importing Project and setting up remote connections to GitHub
Unfortunately I do not have time to write out every little detail. So there are some things you should know how to do prior to reading this tutorial.
- Know how to create a project in eclipse.
- Know how to install an Eclipse Plug-in ( Tutorial )
- Know how to Generating SSH keys (Win/msysgit) I'm sorry, i'm a windows user and i don't know how to do this on MAC OS. So mac users you will have to figure this one out. I know that GitHub has a tutorial just for you.. You'll have to search for it.
- Have some knowledge of Repositories and how they work.
Okay, Let's begin.
Install the Eclipse plug-in.
The source URL can is - http://download.eclipse.org/egit/updates
You can view information about eGit @ http://www.eclipse.org/egit/
There are two options from their source URL. Personally, I don't know or understand which is which..so I installed both of them.. From what i do understand, the two are eGit & jGit .. eGit is suposed to have the GUI for eclipse.. I don't know what jGit is for.. But at this point.. i don't care.. install them both unless you know more about the differences.
Create your Key to authenticate with GitHub.
Go to the link below and follow the instructions there. They are pretty dead on and it will work.
http://help.github.com/msysgit-key-setup/
Once you have done the above.. This is the part that no one tells you!
The key is in the wrong place, yep it's stupid I know. The key is in the .ssh folder in your windows profile.
Mine was in C:\Users\Marco\.ssh and I'm on a windows 7 box. So you'll have to find yours if your on a different version of windows. Eclipse looks for the key in a different place. It looks for it in "ssh" not ".ssh" so you have to copy all the files from your .ssh folder to the ssh folder. The ssh folder is in the same location as your .ssh folder. It just does not have a "dot".
Now you are ready to begin using GitHub.
Part 1: New Project and put it to GitHub
- Create a new project.. call it whatever you want "hello world" will work.
- Right click on your project and select "Team" and "Share Project"
- As unorthodox as it may seem.. you have to create a local repository on your machine and then upload it.
so you are going to click on "git" when it prompts you for a repository type and then click "next" - You should see your project name in the window. Select it and click "Create Repository" and then click "finish"
- Now you have created your local "Master" repository. Now it is time to connect it up to github.
- Before you can send anything to GitHub you have to do an inital "Commit" so right click your project, go to "Team" and click on "commit" type some stupid message as it requires and commit your project.
- Now Let's put the project to your GitHub repository. By default if you just create a blank repository at GitHub then it will be blank. So you need to do an inital "push" of the project. Again, right click ---> Team ---> Push
- Go to github and grab your "ssh" link from your repository. and Paste it into the "URI" field and click "next"
- This will take you to the next step. Click the "add all branches spec" and then click finish.
Note: An existing project is the 2 - 9 steps..
Part 2: Importing Project and setting up remote connections to GitHub
- Open the Git Repository View. Do this by going to "window" --> "show view" -- "other". Expand "git" and select "Git Repositories"
- In the toolbar you will see three icons that have "git" in a white square box. Two of them have "green" plus signs. But only one of them says "Clone a git repository and add it to this view" that is the icon you want to click on. I believe it is the second button.
- Paste your SSH URI for your repository that you acquired form GitHub and click "next" DO NOT change the anything else on this page!
- Continue to click next until the process is finished.
- Right Click on your repository connection and click import projects. Follow the wizard and it should create the project for you.
Comments:
I originally built bluApple as a personal utility to rapidly produce websites. Over several years it has slowly grown into a respectable CMS tool. I feel that with support from the community, bluApple Coldpress can become a contender as one of the top CMS products on the market.
Marco G. Williams
Lead Developer & CEO
Marco G. Williams
Lead Developer & CEO


Add a Comment:
You may post code in your comments by surrounding it with [code] and [/code]
Notify me of follow-up comments via email.