Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

fatal: remote server hung up unexpectedly

Tags:

git

bash

github

ssh

I've looked at the other threads with similar questions, but I'm new to git, so most of it didn't make sense :(

Here's the problem:

I can't push a simple readme onto my repository on github.

$ ssh -T [email protected] seems to be working fine.

But whenever I push the README using the following:

$ git push origin master

I get the following error -

ssh: connect to host githum.com port 22: Connection timed out
fatal: The remote end hung up unexpectedly

Notice that it says the host is 'githum.com'. So I must have made a typo when I was setting up the ssh keys for git. How do I correct this and make sure the remote end works properly?

like image 434
Jaidev Deshpande Avatar asked Feb 28 '26 18:02

Jaidev Deshpande


1 Answers

There is a file in .git directory, config. You can fix it there. (You can edit the same with git config -e).

Or use the command to fix the origin:

git remote set-url origin [email protected]:path/to/repo
like image 182
Mitar Avatar answered Mar 03 '26 07:03

Mitar



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!