Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

fatal: I don't handle protocol

Tags:

git

heroku

When I try to push to Heroku, I get the following error messages.

[first_app]$git push heroku master
fatal: I don't handle protocol '[email protected]:yourhttp'

I then took a look at the different versions of Heroku that I have and there seems to be more than one so I tried deleting it but got another error message.

[first_app]$ git remote set-url --delete heroku [email protected]:yourhttp://still-lake-3136.herokuapp.com/.git
fatal: Will not delete all non-push URLs

I searched for similar error messages but was not able to find anything to fix this one. Your help is greatly appreciated.

Here is my config file:

[core]
    repositoryformatversion = 0
    filemode = true
    bare = false
    logallrefupdates = true
    ignorecase = true
[remote "origin"]
    url = [email protected]:wongsteven/first_app.git
    fetch = +refs/heads/*:refs/remotes/origin/*
[branch "master"]
    remote = origin
    merge = refs/heads/master
[remote "heroku"]
    url = [email protected]:yourhttp://still-lake-3136.herokuapp.com/.git
    fetch = +refs/heads/*:refs/remotes/heroku/*
[heroku]
    remote = heroku

not able to push to heroku | git error: cannot handle https | heroku + git submodule needs authentication | error: "fatal: I don't handle protocol ``git` when using bundle install | Git/GitHub can't push to master

like image 264
Steven W. Avatar asked Jun 29 '13 00:06

Steven W.


2 Answers

Put quotes around the url of the Git repository (this worked for me. I'm using Windows 8.1)

like image 159
Sevin7 Avatar answered Sep 24 '22 02:09

Sevin7


The error is in your configuration. This line:

[remote "heroku"]
    url = [email protected]:yourhttp://still-lake-3136.herokuapp.com/.git

Is complete nonsense. I don't know how that line ended up there. You must have copy-pasted something from somewhere the wrong way. My guess is it should look like this:

[remote "heroku"]
    url = [email protected]:still-lake-3136.git

If that does not work you should really follow the instruction here to initiate a remote repository:

https://devcenter.heroku.com/articles/git

In that case you can delete the whole [remote "heroku"] section (actually the 5 last lines) from your config file before proceeding with those instructions.

One of those two (editing the line, or reinitializing the repository) should fix your problem.

like image 32
Casper Avatar answered Sep 22 '22 02:09

Casper