3

I'm a relatively new programmer and have only started using EGit a couple weeks ago for my systems programming class.

I was able to configure a repository on Github and commit/push to it from a local repo on Eclipse (it updates the repo properly), but the problem is that when I do so it pushes from the user on my Xubuntu VM rather than my Github account.

I signed in via Eclipse when prompted during the push (and my credentials were correct), but when looking at the repo on Github it comes up as the User name of my account on the Xubuntu VM.

How would I go about configuring EGit to push as my actual Github account rather than as the local user?

Aaron Krueger
  • 61
  • 1
  • 6
  • 1
    The author and committer can be set for each commit in the _Git Staging_ view. The default for a Git repository can be set in the repository configuration via the `user.name` and `user.email` entries: in the _Git Repositories_ view right-click the repository, choose _Properties_ and click _Add Entry..._. Is that what you were looking for? – howlger Feb 26 '19 at 06:55
  • 1
    Yes! Thank you very much. I also used info from this thread: https://stackoverflow.com/questions/10663492/how-do-i-change-the-default-author-and-committer-in-the-eclipse-git-plugin – Aaron Krueger Feb 26 '19 at 19:18

1 Answers1

1

Here's what helped me solve the issue (from this thread), alongside howlger's comment:

Click Window > Preferences > Team > Git > Configuration
Click Add Entry and enter the key value pairs:

Key: user.name
Value: YourUsernameHere

And

Key: user.email
Value: YourEmailHere
Aaron Krueger
  • 61
  • 1
  • 6