Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EGit / JGit » Can't "push" in a solo usage
Can't "push" in a solo usage [message #1408644] Fri, 15 August 2014 17:30 Go to next message
Bat Galt is currently offline Bat GaltFriend
Messages: 4
Registered: August 2014
Junior Member
Hi!
I am working alone with Eclipse (Kepler Service Release 2) and I am using Egit locally (the git repository is on my hard drive) mainly to benefit from versioning.
I need to "push" (in order to save a newer version of my work) but I can't. I right-click on my project, go to team, then "push to upstream" is grey, inactive ; I can only "Commit...". And it says "No changed items were selected. Do you wish to amend the last commit?".
I am afraid to try, I guess it wouldn't push and replace the old files at best.
Could someone advise me ?
Re: Can't "push" in a solo usage [message #1408883 is a reply to message #1408644] Sat, 16 August 2014 10:56 Go to previous messageGo to next message
Bat Galt is currently offline Bat GaltFriend
Messages: 4
Registered: August 2014
Junior Member
No Message Body

[Updated on: Sun, 17 August 2014 08:46]

Report message to a moderator

Re: Can't "push" in a solo usage [message #1409162 is a reply to message #1408883] Sun, 17 August 2014 08:45 Go to previous messageGo to next message
Bat Galt is currently offline Bat GaltFriend
Messages: 4
Registered: August 2014
Junior Member
When I go to the ressources of the history view, I can only see the name of my project with a green plus, and the yellow cylinder. I can't compare anything and I suspect I am not commiting anything.
I can't add items of my project (I mean classes, jsp, and others) to the index, neither could I remove them from it, although every item's got the cylinder.
I made another git, attached my project to it. Nothing I do seems to matter.

How can I really add my items to the index and compare them through different versions ?

[Updated on: Sun, 17 August 2014 08:47]

Report message to a moderator

Re: Can't "push" in a solo usage [message #1420075 is a reply to message #1408644] Tue, 09 September 2014 13:18 Go to previous messageGo to next message
Matthias Sohn is currently offline Matthias SohnFriend
Messages: 1072
Registered: July 2009
Senior Member
Bat Galt wrote on Fri, 15 August 2014 13:30
Hi!
I am working alone with Eclipse (Kepler Service Release 2) and I am using Egit locally (the git repository is on my hard drive) mainly to benefit from versioning.
I need to "push" (in order to save a newer version of my work) but I can't. I right-click on my project, go to team, then "push to upstream" is grey, inactive ; I can only "Commit...". And it says "No changed items were selected. Do you wish to amend the last commit?".
I am afraid to try, I guess it wouldn't push and replace the old files at best.
Could someone advise me ?


In order to record history with git you need to commit the changes you did in the file system.
When you create a commit the corresponding file versions are stored in the git object database
in your local repository. If you have another repository (typically on a server) you want to send your
new commits to you can use the git push command to transfer your commits created locally to the
other git repository. If you created your local repository from scratch it has no link (so called remote)
to any other git repository. Hence "Push" is disabled. If you have another repository e.g. on GitHub
where you want to push your changes to you first need to configure a remote [1]. Then you should be able
to push.

[1] https://wiki.eclipse.org/EGit/User_Guide#Adding_a_Remote_Configuration
Re: Can't "push" in a solo usage [message #1420079 is a reply to message #1409162] Tue, 09 September 2014 13:22 Go to previous message
Matthias Sohn is currently offline Matthias SohnFriend
Messages: 1072
Registered: July 2009
Senior Member
Bat Galt wrote on Sun, 17 August 2014 04:45
When I go to the ressources of the history view, I can only see the name of my project with a green plus, and the yellow cylinder. I can't compare anything and I suspect I am not commiting anything.
I can't add items of my project (I mean classes, jsp, and others) to the index, neither could I remove them from it, although every item's got the cylinder.
I made another git, attached my project to it. Nothing I do seems to matter.

How can I really add my items to the index and compare them through different versions ?


Open the Git Staging View. It shows the files you modified in the "Unstaged Changes" pane, drag and drop them to the "Staged Changes" pane in order to stage the changes. Provide a commit message and click "Commit" to create a new commit. Find more details here [1].

Did you try the basic tutorial [2] ?

[1] https://wiki.eclipse.org/EGit/User_Guide#Committing_with_the_Staging_View
[2] https://wiki.eclipse.org/EGit/User_Guide#Basic_Tutorial:_Adding_a_project_to_version_control
Previous Topic:"Looking for uncommitted changes" popup freezed
Next Topic:Execute custom command after performing pull using eGit
Goto Forum:
  


Current Time: Fri Aug 23 07:12:57 GMT 2019

Powered by FUDForum. Page generated in 0.01959 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top