Cannot Open Git Upload Pack Error In Eclipse When Cloning Or Pushing Git Repository

473    Asked by Dannasahi in Devops , Asked on Aug 3, 2023

 I am unable to clone or push to a git repository in Eclipse at Bitbucket. I am receiving the error ‘cannot open git-upload-pack’. I have downloaded the sts thrice but have failed. I can still see the error. I have installed SourceTree and it displays the message ‘This is not a valid source path / URL’:

On using git commands for importing the project, it works well. However, I wish to deploy EGit for this work, because I am a novice to git. There is also the android-adt-bundle in the same directory. However, the project exists on GitHub and not Bitbucket. The person I am working with, can find and push data from the Bitbucket repository. I am currently working on Windows 7. Can you solve the problem?

Answered by Diana Campbell

You need to create the SSH key stuff if you can’t open the git upload pack. You can download and install mysys git as per the GitHub instructions available at http://help.github.com


        In C:/Users/you/ssh conceal any present keys in the subdirectory. In case the ssh directory is not present, generate it. The username is ‘you’. 

In the start menu, run the git-bash command shell and in the shell, create an rsa key according to the email: ssh-keygen-t rsa -C “you@wherever.com” and give your passphrase and confirm.The earlier step must have produced C:/User/you/ssh/id_rsa.pub which can be opened in the text editor. Navigate to account settings at github. Then move to SSH keys, include a key, and paste it in the key box.

In Git-bash, see the back-ticks in the following line:
Eval ‘ssh-agent’
Ssh-add C: /User/you/ssh/id_rsa
Ssh git@github.com

So, you ran the ssh-agent that was required by ssh-add. After that you deployed the ssh-add to understand the location of the key. This was followed by trying to ssh to GitHub. The answer to this final command must be that you have clearly validated at GitHub but you do not possess shell access. This is a mere validation test. In case the validation was not successful, it can solved through the verbose version mentioned below:

Ssh -v git@github.com
You can also configure the remote push in Eclipse by following the below-mentioned steps:
Going to Window > SHow View > Git > Git Repositories will include a repository explorer window.
Choose the repository and stretch and right click Remotes and select Create Remote, in the repository window.
Now copy the GitHub repository URI from the GitHub repository page and paste it in the available URI box.
Choose ssh as the protocol and return to the URI box and include git+ at the starting to get a look like the one below:
 Git + ssh / git@github.com/ UserName/ProjectName.git
Erase the leading slash from the Repository Path box.
Select Next. In case you see “auth fail”, restart eclipse and repeat step 5.
After clearing the authentication, choose Master in the following dialog for source ref, and select Add all branches spec, and finally click on Finish.

The DevOps Certification Training at JanBask Training offers experience like offline classes, saving students from the hassle of traveling to the physical location. The training provides a total DevOps discipline preparation by teaching the core concept and techniques that the job role demands. The training also gives extensive training to impart fundamental and advanced concepts through interesting e-tools and expert-led DevOps classes. Furthermore, JanBask Training helps you get job-ready and face the tough competitive market with confidence.



Your Answer

Interviews

Parent Categories