Push to gist returns a strange error

I cloned the gist using the Public Clone URL. I made my changes, added and committed. However, when I run git push origin master , I get the following error:

 fatal: remote error: You can't push to git://github.com/1234567.git Use git@github.com :1234567.git 

but according to git remote -v source should be in the subdomain of gist.github.com

 origin git://gist.github.com/1234567.git (fetch) origin git://gist.github.com/1234567.git (push) 

Any ideas on how to fix this error? Thanks!

+6
source share
1 answer

Have you tried to go to the remote URL that the error suggests? Try to do:

 git remote set-url --push origin git@github.com :1234567.git 

You are currently connecting to HTTP and want you to connect to SSH.

+23
source

Source: https://habr.com/ru/post/896242/


All Articles