Cannot push to Git repository on Bitbucket

后端 未结 21 694
春和景丽
春和景丽 2020-11-29 14:40

I created a new repository and I\'m running into a strange error. I\'ve used Git before on Bitbucket but I just reformatted and now I can\'t seem to get Git to work. After

21条回答
  •  再見小時候
    2020-11-29 15:25

    For errors:

    [error] repository access denied. access via a deployment key is read-only. fatal: Could not read from remote repository. Please make sure you have the correct access rights and the repository exists.

    [error] fatal: Could not read from remote repository.

    [error] fatal: Unable to find remote helper for 'https'

    I solved following this steps:

    First install this dependencies:

    $ yum install expat expat-devel openssl openssl-devel
    

    Then remove git:

    $ yum remove git git-all
    

    Now Build and install Git on last version, in this case:

    $ wget https://github.com/git/git/archive/v2.13.0.tar.gz
    $ tar zxf v.2.13.0.tar.gz
    $ cd git-2.13.0/
    

    Then for the configure:

    $ make configure
    $ ./configure --with-expat --with-openssl
    

    And finally install like this:

    $ make 
    $ make install install-doc install-html install-info
    

    that´s it, now configure your repo with https:

    $ git remote add origin https://github.com/*user*/*repo*.git
    # Verify new remote
    $ git remote -v
    

    if you have configured an ssh key in your remote server you have to delete it.

提交回复
热议问题