Daniel 'MaTachi' Jonsson

Tag Archives: Eclipse

How to Set Up Egit with Github in Eclipse

When I the other day tried to set up Egit in Eclipse Indigo with Github I had major problems with guides not working. Two of the tutorials I tried where:

I got many errors and such… :/

But I found a really good post describing how to set it up in a current version of Eclipse:

2. In eclipse, configure the remote push
a. Window > Show View > Git > Git Repositories will add a repository explorer window.
b. In the repository window, select the repository and expand and right-click Remotes and choose Create Remote.
c. Copy the github repository URI from the github repository page and paste this in the URI box.
d. Select ssh as the protocol but then go back to the URI box and add “git+” at the beginning so it looks like this: git+ssh://git@github.com/UserName/ProjectName.git
e. In the Repository Path box, remove the leading slash
f. Hit next and cross your fingers. If your get “auth fail” restart eclipse and try step 5 again.
g. When you get past the authentication, in the next dialog select “master” for source ref, click “Add all branches spec” and “Finish”.

Now try a push to github. This worked for me but with all the fiddling around I’m not sure these instructions are perfect….

Link to the post: http://www.eclipse.org/forums/index.php/mv/msg/200890/648905/#msg_648905

Fix Autocomplete in Eclipse

My ability to autocomplete code in Eclipse just stopped to work. But the problem was easily solved by doing the following steps: Open the Preferences window, navigate to Java > Editor > Content Assist > Advanced, tick everything that sounds right and finally Press OK.

If you have another possible solution, please share it below in a comment.

Dark Theme to Eclipse, Notepad++, Visual Studio and Vim

Hi! In this post I just want to recommend a nice theme that is available to the popular text editors and IDEs Eclipse, Notepad++, Visual Studio and Vim. It’s called Prabir’s Dark Theme and I have a link to the download page below. I’m using the theme in Eclipse and it works great.

Prabir's Dark Theme

Prabir's Dark Theme

java.lang.nullpointerexception when editing strings.xml

I have downloaded Android SDK to Eclipse 3.6 and I have started to mess around and see if I can create something to Android. But when I opened [project folder]/res/values/strings.xml and tried to edit it in the Resources view, I got the following error message:


This was solved by switching to the normal XML view and changing the following line:



<resources xmlns:android="http://schemas.android.com/apk/res/android">

And now does the Resources view work!

You also have to reopen the file after you have changed the code line.